pub struct ShardStateStuff { /* private fields */ }Expand description
Parsed shard state.
Implementations§
Source§impl ShardStateStuff
impl ShardStateStuff
pub fn construct_split_root(left: Cell, right: Cell) -> Result<Cell>
pub fn from_root( block_id: &BlockId, root: Cell, handle: RefMcStateHandle, ) -> Result<Self>
pub fn from_state_and_root( block_id: &BlockId, shard_state: Box<ShardStateUnsplit>, root: Cell, handle: RefMcStateHandle, ) -> Result<Self>
pub fn block_id(&self) -> &BlockId
pub fn state(&self) -> &ShardStateUnsplit
pub fn state_extra(&self) -> Result<&McStateExtra>
pub fn ref_mc_state_handle(&self) -> &RefMcStateHandle
pub fn root_cell(&self) -> &Cell
pub fn shards(&self) -> Result<&ShardHashes>
pub fn config_params(&self) -> Result<&BlockchainConfig>
pub fn get_gen_chain_time(&self) -> u64
pub fn get_top_shards(&self) -> Result<Vec<ShardIdent>>
Sourcepub fn track_usage(
&self,
usage_mode: UsageTreeMode,
) -> Result<(UsageTree, Self)>
pub fn track_usage( &self, usage_mode: UsageTreeMode, ) -> Result<(UsageTree, Self)>
Creates a derived state which tracks access to cells data and references.
Sourcepub fn par_make_next_state(
&self,
next_block_id: &BlockId,
merkle_update: &MerkleUpdate,
split_at_depth: Option<u8>,
) -> Result<Self>
pub fn par_make_next_state( &self, next_block_id: &BlockId, merkle_update: &MerkleUpdate, split_at_depth: Option<u8>, ) -> Result<Self>
Applies merkle update of the specified block and preserves
the tracker from the initial state.
NOTE: Call from inside rayon.
Trait Implementations§
Source§impl AsRef<ShardStateUnsplit> for ShardStateStuff
impl AsRef<ShardStateUnsplit> for ShardStateStuff
Source§fn as_ref(&self) -> &ShardStateUnsplit
fn as_ref(&self) -> &ShardStateUnsplit
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl Clone for ShardStateStuff
impl Clone for ShardStateStuff
Source§fn clone(&self) -> ShardStateStuff
fn clone(&self) -> ShardStateStuff
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl RefCnt for ShardStateStuff
impl RefCnt for ShardStateStuff
Source§fn into_ptr(me: Self) -> *mut Self::Base
fn into_ptr(me: Self) -> *mut Self::Base
Converts the smart pointer into a raw pointer, without affecting the reference count. Read more
Source§fn as_ptr(me: &Self) -> *mut Self::Base
fn as_ptr(me: &Self) -> *mut Self::Base
Provides a view into the smart pointer as a raw pointer. Read more
Auto Trait Implementations§
impl Freeze for ShardStateStuff
impl !RefUnwindSafe for ShardStateStuff
impl Send for ShardStateStuff
impl Sync for ShardStateStuff
impl Unpin for ShardStateStuff
impl !UnwindSafe for ShardStateStuff
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more