Trait client_traits::StateClient[][src]

pub trait StateClient {
    type State: StateInfo;
    fn latest_state_and_header(&self) -> (Self::State, Header);
fn state_at(&self, id: BlockId) -> Option<Self::State>; }

Provides methods to access chain state

Associated Types

type State: StateInfo[src]

Type representing chain state

Loading content...

Required methods

fn latest_state_and_header(&self) -> (Self::State, Header)[src]

Get a copy of the best block’s state and header.

fn state_at(&self, id: BlockId) -> Option<Self::State>[src]

Attempt to get a copy of a specific block’s final state.

This will not fail if given BlockId::Latest. Otherwise, this can fail (but may not) if the DB prunes state or the block is unknown.

Loading content...

Implementors

Loading content...