pub struct ModuleCacheEntry<'config>(_);
Expand description

Module level cache entry.

Implementations§

Create the cache entry.

Gets cached data if state matches, otherwise calls compute.

Data is automatically serialized/deserialized with bincode.

Gets cached data if state matches, otherwise calls compute.

If the cache is disabled or no cached data is found then compute is called to calculate the data. If the data was found in cache it is passed to deserialize, which if successful will be the returned value. When computed the serialize function is used to generate the bytes from the returned value.

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.

Calls U::from(self).

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

Should always be Self
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.