pub trait InfallibleValueStorage<T>: ValueStorage<T> {
// Required method
fn map_into_value<Output, Present>(
storage: Self::Storage,
present: Present,
) -> Output
where Present: FnOnce(T) -> Output;
}Expand description
Storage policies whose holder-to-model conversion cannot fail because the storage representation always contains a value.
Required Methods§
Sourcefn map_into_value<Output, Present>(
storage: Self::Storage,
present: Present,
) -> Outputwhere
Present: FnOnce(T) -> Output,
fn map_into_value<Output, Present>(
storage: Self::Storage,
present: Present,
) -> Outputwhere
Present: FnOnce(T) -> Output,
Convert storage into an output value without a missing-value fallback.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".