pub trait SimpleStorageType<'a>:
StorageType
+ Erase
+ Into<Self::Wraps<'a>>where
Self: 'a,{
// Required method
fn set_by_wrapped(&mut self, value: Self::Wraps<'a>);
}
Expand description
Trait for simple accessors that store no more than their wrapped value. The type’s representation must be entirely inline, or storage leaks become possible. Note: it is a logic error if erasure does anything more than writing the zero-value.
Required Methods§
Sourcefn set_by_wrapped(&mut self, value: Self::Wraps<'a>)
fn set_by_wrapped(&mut self, value: Self::Wraps<'a>)
Write the value to persistent storage.
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.