pub trait QueryTrait<N>where
N: Network,{
// Required methods
fn current_state_root(&self) -> Result<<N as Network>::StateRoot, Error>;
fn current_state_root_async<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<<N as Network>::StateRoot, Error>> + 'async_trait>>
where 'life0: 'async_trait,
Self: 'async_trait;
fn get_state_path_for_commitment(
&self,
commitment: &Field<N>,
) -> Result<StatePath<N>, Error>;
fn get_state_path_for_commitment_async<'life0, 'life1, 'async_trait>(
&'life0 self,
commitment: &'life1 Field<N>,
) -> Pin<Box<dyn Future<Output = Result<StatePath<N>, Error>> + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait;
}Required Methods§
Sourcefn current_state_root(&self) -> Result<<N as Network>::StateRoot, Error>
fn current_state_root(&self) -> Result<<N as Network>::StateRoot, Error>
Returns the current state root.
Sourcefn current_state_root_async<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<<N as Network>::StateRoot, Error>> + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn current_state_root_async<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<<N as Network>::StateRoot, Error>> + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Returns the current state root.
Sourcefn get_state_path_for_commitment(
&self,
commitment: &Field<N>,
) -> Result<StatePath<N>, Error>
fn get_state_path_for_commitment( &self, commitment: &Field<N>, ) -> Result<StatePath<N>, Error>
Returns a state path for the given commitment.
Sourcefn get_state_path_for_commitment_async<'life0, 'life1, 'async_trait>(
&'life0 self,
commitment: &'life1 Field<N>,
) -> Pin<Box<dyn Future<Output = Result<StatePath<N>, Error>> + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
fn get_state_path_for_commitment_async<'life0, 'life1, 'async_trait>(
&'life0 self,
commitment: &'life1 Field<N>,
) -> Pin<Box<dyn Future<Output = Result<StatePath<N>, Error>> + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Returns a state path for the given commitment.