Trait storage_interface::DBReaderForPoW
source · pub trait DBReaderForPoW: Send + Sync + DbReader {
// Required methods
fn get_latest_ledger_info_option(&self) -> Option<LedgerInfoWithSignatures>;
fn get_block_ledger_info(
&self,
consensus_block_id: &HashValue
) -> Result<LedgerInfoWithSignatures>;
fn get_events_by_version(
&self,
start_version: u64,
end_version: u64
) -> Result<Vec<ContractEvent>>;
fn get_epoch_ending_blocks(
&self,
start_epoch: u64,
end_epoch: u64
) -> Result<Vec<HashValue>>;
fn get_reward_event(&self, epoch: u64) -> Result<RewardDistributionEventV2>;
fn get_committed_block_by_hash(
&self,
block_hash: &HashValue
) -> Result<CommittedBlock>;
fn get_committed_block_hash_by_view(&self, view: u64) -> Result<HashValue>;
fn get_ledger_info_by_voted_block(
&self,
block_id: &HashValue
) -> Result<LedgerInfoWithSignatures>;
fn get_block_hash_by_epoch_and_round(
&self,
epoch: u64,
round: u64
) -> Result<HashValue>;
}
Required Methods§
fn get_latest_ledger_info_option(&self) -> Option<LedgerInfoWithSignatures>
sourcefn get_block_ledger_info(
&self,
consensus_block_id: &HashValue
) -> Result<LedgerInfoWithSignatures>
fn get_block_ledger_info( &self, consensus_block_id: &HashValue ) -> Result<LedgerInfoWithSignatures>
TODO(lpl): It’s possible to use round number?