Trait WithdrawalsProvider
pub trait WithdrawalsProvider: Send + Sync {
// Required methods
fn withdrawals_by_block(
&self,
id: HashOrNumber,
timestamp: u64,
) -> Result<Option<Withdrawals>, ProviderError>;
fn latest_withdrawal(&self) -> Result<Option<Withdrawal>, ProviderError>;
}
Expand description
Client trait for fetching [Withdrawal] related data.
Required Methods§
fn withdrawals_by_block(
&self,
id: HashOrNumber,
timestamp: u64,
) -> Result<Option<Withdrawals>, ProviderError>
fn withdrawals_by_block( &self, id: HashOrNumber, timestamp: u64, ) -> Result<Option<Withdrawals>, ProviderError>
Get withdrawals by block id.
fn latest_withdrawal(&self) -> Result<Option<Withdrawal>, ProviderError>
fn latest_withdrawal(&self) -> Result<Option<Withdrawal>, ProviderError>
Get latest withdrawal from this block or earlier .
Implementations on Foreign Types§
§impl<'a, T> WithdrawalsProvider for &'a T
impl<'a, T> WithdrawalsProvider for &'a T
fn withdrawals_by_block( &self, id: HashOrNumber, timestamp: u64, ) -> Result<Option<Withdrawals>, ProviderError>
fn latest_withdrawal(&self) -> Result<Option<Withdrawal>, ProviderError>
§impl<T> WithdrawalsProvider for Arc<T>
impl<T> WithdrawalsProvider for Arc<T>
fn withdrawals_by_block( &self, id: HashOrNumber, timestamp: u64, ) -> Result<Option<Withdrawals>, ProviderError>
fn latest_withdrawal(&self) -> Result<Option<Withdrawal>, ProviderError>
Implementors§
impl WithdrawalsProvider for MockEthProvider
Available on crate feature
test-utils
only.impl WithdrawalsProvider for NoopProvider
Available on crate feature
test-utils
only.