pub trait Batch: CloneBox {
// Required methods
fn put<'life0, 'life1, 'life2, 'async_trait>(
&'life0 mut self,
key: &'life1 [u8],
value: &'life2 [u8]
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn delete<'life0, 'life1, 'async_trait>(
&'life0 mut self,
key: &'life1 [u8]
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn size<'life0, 'async_trait>(
&'life0 self
) -> Pin<Box<dyn Future<Output = Result<usize>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn write<'life0, 'async_trait>(
&'life0 self
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn reset<'life0, 'async_trait>(
&'life0 mut self
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn replay<'life0, 'async_trait>(
&'life0 self,
k: Arc<Mutex<BoxedDatabase>>
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}
Expand description
Required Methods§
fn put<'life0, 'life1, 'life2, 'async_trait>( &'life0 mut self, key: &'life1 [u8], value: &'life2 [u8] ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait,
fn delete<'life0, 'life1, 'async_trait>( &'life0 mut self, key: &'life1 [u8] ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,
sourcefn size<'life0, 'async_trait>(
&'life0 self
) -> Pin<Box<dyn Future<Output = Result<usize>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn size<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<usize>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,
Retrieves the amount of data queued up for writing, this includes the keys, values, and deleted keys.
sourcefn write<'life0, 'async_trait>(
&'life0 self
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn write<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,
Flushes any accumulated data to disk.