Struct warmy::load::Storage

source ·
pub struct Storage<C, K> { /* private fields */ }
Expand description

Resource storage.

This type is responsible for storing resources, giving functions to look them up and update them whenever needed.

Implementations§

The canonicalized root the Storage is configured with.

Get a resource from the Storage and return an error if its loading failed.

This function uses the default loading method.

Get a resource from the Storage by using a specific method and return and error if its loading failed.

Get a resource from the Storage for the given key. If it fails, a proxied version is used, which will get replaced by the resource once it’s available and reloaded.

This function uses the default loading method.

Get a resource from the Storage for the given key by using a specific method. If it fails, a proxied version is used, which will get replaced by the resource once it’s available and reloaded.

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Inspect the context.
Inspect the context.
Inspect the context.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.