Trait holochain::prelude::ReadAccess
source · pub trait ReadAccess<Kind>: Clone + Into<DbRead<Kind>>where
Kind: DbKindT,{
// Required methods
fn read_async<'life0, 'async_trait, E, R, F>(
&'life0 self,
f: F
) -> Pin<Box<dyn Future<Output = Result<R, E>> + Send + 'async_trait, Global>>
where 'life0: 'async_trait,
E: From<DatabaseError> + Send + 'static + 'async_trait,
F: FnOnce(Transaction<'_>) -> Result<R, E> + Send + 'static + 'async_trait,
R: Send + 'static + 'async_trait,
Self: 'async_trait;
fn kind(&self) -> &Kind;
}
Expand description
Required Methods§
sourcefn read_async<'life0, 'async_trait, E, R, F>(
&'life0 self,
f: F
) -> Pin<Box<dyn Future<Output = Result<R, E>> + Send + 'async_trait, Global>>where
'life0: 'async_trait,
E: From<DatabaseError> + Send + 'static + 'async_trait,
F: FnOnce(Transaction<'_>) -> Result<R, E> + Send + 'static + 'async_trait,
R: Send + 'static + 'async_trait,
Self: 'async_trait,
fn read_async<'life0, 'async_trait, E, R, F>( &'life0 self, f: F ) -> Pin<Box<dyn Future<Output = Result<R, E>> + Send + 'async_trait, Global>>where 'life0: 'async_trait, E: From<DatabaseError> + Send + 'static + 'async_trait, F: FnOnce(Transaction<'_>) -> Result<R, E> + Send + 'static + 'async_trait, R: Send + 'static + 'async_trait, Self: 'async_trait,
Run an async read transaction on a background thread.