reth_storage_api

Trait WithdrawalsProvider

Source
pub trait WithdrawalsProvider: Send + Sync {
    // Required methods
    fn withdrawals_by_block(
        &self,
        id: BlockHashOrNumber,
        timestamp: u64,
    ) -> ProviderResult<Option<Withdrawals>>;
    fn latest_withdrawal(&self) -> ProviderResult<Option<Withdrawal>>;
}
Expand description

Client trait for fetching [Withdrawal] related data.

Required Methods§

Source

fn withdrawals_by_block( &self, id: BlockHashOrNumber, timestamp: u64, ) -> ProviderResult<Option<Withdrawals>>

Get withdrawals by block id.

Source

fn latest_withdrawal(&self) -> ProviderResult<Option<Withdrawal>>

Get latest withdrawal from this block or earlier .

Implementations on Foreign Types§

Source§

impl<'a, T: 'a + WithdrawalsProvider + ?Sized> WithdrawalsProvider for &'a T
where &'a T: Send + Sync,

Source§

fn withdrawals_by_block( &self, id: BlockHashOrNumber, timestamp: u64, ) -> ProviderResult<Option<Withdrawals>>

Source§

fn latest_withdrawal(&self) -> ProviderResult<Option<Withdrawal>>

Source§

impl<T: WithdrawalsProvider + ?Sized> WithdrawalsProvider for Arc<T>
where Arc<T>: Send + Sync,

Source§

fn withdrawals_by_block( &self, id: BlockHashOrNumber, timestamp: u64, ) -> ProviderResult<Option<Withdrawals>>

Source§

fn latest_withdrawal(&self) -> ProviderResult<Option<Withdrawal>>

Implementors§

Source§

impl<C: Send + Sync, N: NodePrimitives> WithdrawalsProvider for NoopProvider<C, N>