pub trait BurnStateDB {
Show 14 methods // Required methods fn get_v1_unlock_height(&self) -> u32; fn get_v2_unlock_height(&self) -> u32; fn get_pox_3_activation_height(&self) -> u32; fn get_burn_block_height(&self, sortition_id: &SortitionId) -> Option<u32>; fn get_burn_start_height(&self) -> u32; fn get_pox_prepare_length(&self) -> u32; fn get_pox_reward_cycle_length(&self) -> u32; fn get_pox_rejection_fraction(&self) -> u64; fn get_burn_header_hash( &self, height: u32, sortition_id: &SortitionId ) -> Option<BurnchainHeaderHash>; fn get_sortition_id_from_consensus_hash( &self, consensus_hash: &ConsensusHash ) -> Option<SortitionId>; fn get_stacks_epoch( &self, height: u32 ) -> Option<StacksEpoch<ExecutionCost>>; fn get_stacks_epoch_by_epoch_id( &self, epoch_id: &StacksEpochId ) -> Option<StacksEpoch<ExecutionCost>>; fn get_ast_rules(&self, height: u32) -> ASTRules; fn get_pox_payout_addrs( &self, height: u32, sortition_id: &SortitionId ) -> Option<(Vec<TupleData>, u128)>;
}

Required Methods§

fn get_v1_unlock_height(&self) -> u32

fn get_v2_unlock_height(&self) -> u32

fn get_pox_3_activation_height(&self) -> u32

fn get_burn_block_height(&self, sortition_id: &SortitionId) -> Option<u32>

Returns the burnchain block height for the sortition_id is associated with.

fn get_burn_start_height(&self) -> u32

Returns the height of the burnchain when the Stacks chain started running.

fn get_pox_prepare_length(&self) -> u32

fn get_pox_reward_cycle_length(&self) -> u32

fn get_pox_rejection_fraction(&self) -> u64

fn get_burn_header_hash( &self, height: u32, sortition_id: &SortitionId ) -> Option<BurnchainHeaderHash>

Returns the burnchain header hash for the given burn block height, as queried from the given SortitionId.

Returns Some if self.get_burn_start_height() <= height < self.get_burn_block_height(sorition_id), and None otherwise.

fn get_sortition_id_from_consensus_hash( &self, consensus_hash: &ConsensusHash ) -> Option<SortitionId>

Lookup a SortitionId keyed to a ConsensusHash.

Returns None if no block found.

fn get_stacks_epoch(&self, height: u32) -> Option<StacksEpoch<ExecutionCost>>

The epoch is defined as by a start and end height. This returns the epoch enclosing height.

fn get_stacks_epoch_by_epoch_id( &self, epoch_id: &StacksEpochId ) -> Option<StacksEpoch<ExecutionCost>>

fn get_ast_rules(&self, height: u32) -> ASTRules

fn get_pox_payout_addrs( &self, height: u32, sortition_id: &SortitionId ) -> Option<(Vec<TupleData>, u128)>

Get the PoX payout addresses for a given burnchain block

Trait Implementations§

§

impl BurnStateDB for &dyn BurnStateDB

§

fn get_v1_unlock_height(&self) -> u32

§

fn get_v2_unlock_height(&self) -> u32

§

fn get_pox_3_activation_height(&self) -> u32

§

fn get_burn_block_height(&self, sortition_id: &SortitionId) -> Option<u32>

Returns the burnchain block height for the sortition_id is associated with.
§

fn get_sortition_id_from_consensus_hash( &self, consensus_hash: &ConsensusHash ) -> Option<SortitionId>

Lookup a SortitionId keyed to a ConsensusHash. Read more
§

fn get_burn_start_height(&self) -> u32

Returns the height of the burnchain when the Stacks chain started running.
§

fn get_burn_header_hash( &self, height: u32, sortition_id: &SortitionId ) -> Option<BurnchainHeaderHash>

Returns the burnchain header hash for the given burn block height, as queried from the given SortitionId. Read more
§

fn get_stacks_epoch(&self, height: u32) -> Option<StacksEpoch<ExecutionCost>>

The epoch is defined as by a start and end height. This returns the epoch enclosing height.
§

fn get_pox_prepare_length(&self) -> u32

§

fn get_pox_reward_cycle_length(&self) -> u32

§

fn get_pox_rejection_fraction(&self) -> u64

§

fn get_stacks_epoch_by_epoch_id( &self, epoch_id: &StacksEpochId ) -> Option<StacksEpoch<ExecutionCost>>

§

fn get_ast_rules(&self, height: u32) -> ASTRules

§

fn get_pox_payout_addrs( &self, height: u32, sortition_id: &SortitionId ) -> Option<(Vec<TupleData>, u128)>

Get the PoX payout addresses for a given burnchain block

Implementations on Foreign Types§

source§

impl BurnStateDB for BurnDatastore

source§

fn get_burn_block_height(&self, sortition_id: &SortitionId) -> Option<u32>

Returns the burnchain block height for the sortition_id is associated with.

source§

fn get_burn_start_height(&self) -> u32

Returns the height of the burnchain when the Stacks chain started running.

source§

fn get_burn_header_hash( &self, height: u32, sortition_id: &SortitionId ) -> Option<BurnchainHeaderHash>

Returns the burnchain header hash for the given burn block height, as queried from the given SortitionId.

Returns Some if self.get_burn_start_height() <= height < self.get_burn_block_height(sorition_id), and None otherwise.

source§

fn get_sortition_id_from_consensus_hash( &self, consensus_hash: &ConsensusHash ) -> Option<SortitionId>

Lookup a SortitionId keyed to a ConsensusHash.

Returns None if no block found.

source§

fn get_stacks_epoch(&self, height: u32) -> Option<StacksEpoch<ExecutionCost>>

The epoch is defined as by a start and end height. This returns the epoch enclosing height.

source§

fn get_pox_payout_addrs( &self, height: u32, sortition_id: &SortitionId ) -> Option<(Vec<TupleData>, u128)>

Get the PoX payout addresses for a given burnchain block

source§

fn get_v1_unlock_height(&self) -> u32

source§

fn get_v2_unlock_height(&self) -> u32

source§

fn get_pox_3_activation_height(&self) -> u32

source§

fn get_pox_prepare_length(&self) -> u32

source§

fn get_pox_reward_cycle_length(&self) -> u32

source§

fn get_pox_rejection_fraction(&self) -> u64

source§

fn get_stacks_epoch_by_epoch_id( &self, epoch_id: &StacksEpochId ) -> Option<StacksEpoch<ExecutionCost>>

source§

fn get_ast_rules(&self, height: u32) -> ASTRules

Implementors§