Trait de_objects::collection::AssetCollectionLoader
source · pub(crate) trait AssetCollectionLoader{
const DIRECTORY: &'static str;
const SUFFIX: &'static str;
// Required methods
fn new(map: AHashMap<Self::Key, Handle<Self::Asset>>) -> Self;
fn label() -> Option<String>;
// Provided methods
fn init(server: &AssetServer) -> Self { ... }
fn progress(&self, server: &AssetServer) -> Progress { ... }
}
Required Associated Constants§
Required Methods§
Provided Methods§
sourcefn init(server: &AssetServer) -> Self
fn init(server: &AssetServer) -> Self
Initialize the collection by (starting) loading of all assets of the collection.
sourcefn progress(&self, server: &AssetServer) -> Progress
fn progress(&self, server: &AssetServer) -> Progress
Returns progress of the loading.
It shall not be called before Self::init
.
§Panics
Panics if loading any of the assets is either failed or unknown.
Object Safety§
This trait is not object safe.