pub trait StateStorageNew: StateStorage {
// Required method
fn new<T, State>(value: T) -> Self::Inner<T, State>
where T: StateMachineImpl,
<Self::Machine<T> as StateMachineImpl>::Standin: Initial<State>;
}Expand description
Storage backend that can create initial owned state.
This is the capability behind State::new. The Initial bound prevents
raw runtime data from being introduced in a non-initial state.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementors§
impl StateStorageNew for StorageStateOwned
impl StateStorageNew for StorageStateOwnedBox
impl StateStorageNew for StorageStateOwnedPinBox
Available on crate feature
alloc only.