Trait VersionedStateStore
pub trait VersionedStateStore<V>: VersionedStateStoreR<V>where
V: VersionIdentifier,{
// Required method
fn atomic_write<'a>(
&'a self,
base: Option<&V>,
version_id: &V,
changes: Box<dyn Iterator<Item = (Key, Option<Value>)> + 'a>,
) -> Result<(), VersionedStateStoreError>;
}Expand description
Storage with versioning.
Required Methods§
fn atomic_write<'a>(
&'a self,
base: Option<&V>,
version_id: &V,
changes: Box<dyn Iterator<Item = (Key, Option<Value>)> + 'a>,
) -> Result<(), VersionedStateStoreError>
fn atomic_write<'a>( &'a self, base: Option<&V>, version_id: &V, changes: Box<dyn Iterator<Item = (Key, Option<Value>)> + 'a>, ) -> Result<(), VersionedStateStoreError>
Atomically apply a list of changes described by the iterator to the state of the base
version, saved in the new version. Also set the latest version to version. For each
iterated item, a None value will remove the value if it exists.