Trait eventually::aggregate::repository::Saver
source · pub trait Saver<T>: Send + Syncwhere
T: Aggregate,{
// Required method
fn save<'life0, 'life1, 'async_trait>(
&'life0 self,
root: &'life1 mut Root<T>
) -> Pin<Box<dyn Future<Output = Result<(), SaveError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}
Expand description
Trait used to implement write access to a data store, which can be used to save the latest state of an aggregate::Root instance.
Required Methods§
sourcefn save<'life0, 'life1, 'async_trait>(
&'life0 self,
root: &'life1 mut Root<T>
) -> Pin<Box<dyn Future<Output = Result<(), SaveError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save<'life0, 'life1, 'async_trait>(
&'life0 self,
root: &'life1 mut Root<T>
) -> Pin<Box<dyn Future<Output = Result<(), SaveError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Saves a new version of an aggregate::Root instance to the data store.