pub trait Cached: Sized {
type Cache: Clone;
// Required methods
fn load(cache: &Self::Cache) -> Self;
fn cache(self, group: Group, previous: Option<Self::Cache>) -> Self::Cache;
}
Expand description
A piece of data that can be cached.
Required Associated Types§
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.