Struct everscale_types::models::block::ShardHashes
source · pub struct ShardHashes<C: CellFamily>(_);Expand description
A tree of the most recent descriptions for all currently existing shards for all workchains except the masterchain.
Implementations§
source§impl<C> ShardHashes<C>where
for<'c> C: CellFamily + 'c,
impl<C> ShardHashes<C>where for<'c> C: CellFamily + 'c,
sourcepub fn iter(&self) -> ShardHashesIter<'_, C> ⓘ
pub fn iter(&self) -> ShardHashesIter<'_, C> ⓘ
Gets an iterator over the entries of the shard description trees, sorted by
shard ident. The iterator element is Result<(ShardIdent, ShardDescription<C>)>.
If the dict or tree is invalid, finishes after the first invalid element. returning an error.
sourcepub fn raw_iter(&self) -> ShardHashesRawIter<'_, C> ⓘ
pub fn raw_iter(&self) -> ShardHashesRawIter<'_, C> ⓘ
Gets an iterator over the raw entries of the shard description trees, sorted by
shard ident. The iterator element is Result<(ShardIdent, CellSlice<C>)>.
If the dict or tree is invalid, finishes after the first invalid element, returning an error.
sourcepub fn latest_blocks(&self) -> LatestBlocksIter<'_, C> ⓘ
pub fn latest_blocks(&self) -> LatestBlocksIter<'_, C> ⓘ
Gets an iterator over the latest blocks in all shards, sorted by
shard ident. The iterator element is Result<BlockId>.
If the dict or tree is invalid, finishes after the first invalid element, returning an error.
sourcepub fn get_workchain_shards(
&self,
workchain: i32
) -> Result<Option<WorkchainShardHashes<C>>, Error>where
C: DefaultFinalizer,
pub fn get_workchain_shards( &self, workchain: i32 ) -> Result<Option<WorkchainShardHashes<C>>, Error>where C: DefaultFinalizer,
Returns a shards description tree root for the specified workchain.
sourcepub fn contains_workchain<Q>(&self, workchain: i32) -> Result<bool, Error>where
C: DefaultFinalizer,
pub fn contains_workchain<Q>(&self, workchain: i32) -> Result<bool, Error>where C: DefaultFinalizer,
Returns true if the dictionary contains a workchain for the specified id.