package speiger.src.coreengine.assets.base;

import java.nio.file.attribute.FileTime;
import java.util.Map;
import java.util.function.Predicate;

import speiger.src.coreengine.assets.AssetLocation;

public interface IAssetProvider {

	public IAsset getAsset(AssetLocation location);
	public MultiAsset getAllAssets(AssetLocation location);
	public FileTime getModifiedTime(AssetLocation location);
	public FileTime getLatestTime(AssetLocation...locations);
	public Map<AssetLocation, IAsset> listAssets(String folder, Predicate<AssetLocation> filter);
	public Map<AssetLocation, MultiAsset> listAllAssets(String folder, Predicate<AssetLocation> filter);
	
	public static interface ICloseableAssetProvider extends IAssetProvider, AutoCloseable {
		@Override
		public void close();
	}
}
