Trait DatastoreAdapter

Source
pub trait DatastoreAdapter {
    type Transaction: SimpleTransaction;

    // Required methods
    fn transaction<'life0, 'async_trait>(
        &'life0 self,
        rw: bool,
    ) -> Pin<Box<dyn Future<Output = Result<Self::Transaction, Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn path(&self) -> &str;

    // Provided methods
    fn default() -> Self
       where Self: Sized { ... }
    fn spawn(&self) -> Self
       where Self: Sized { ... }
}

Required Associated Types§

Required Methods§

Source

fn transaction<'life0, 'async_trait>( &'life0 self, rw: bool, ) -> Pin<Box<dyn Future<Output = Result<Self::Transaction, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn path(&self) -> &str

Provided Methods§

Source

fn default() -> Self
where Self: Sized,

Source

fn spawn(&self) -> Self
where Self: Sized,

Implementors§