Trait ethers_middleware::gas_escalator::GasEscalator
source · pub trait GasEscalator: Send + Sync + Debug {
// Required method
fn get_gas_price(&self, initial_price: U256, time_elapsed: u64) -> U256;
}
Expand description
Trait for fetching updated gas prices after a transaction has been first broadcast
Required Methods§
sourcefn get_gas_price(&self, initial_price: U256, time_elapsed: u64) -> U256
fn get_gas_price(&self, initial_price: U256, time_elapsed: u64) -> U256
Given the initial gas price and the time elapsed since the transaction’s first broadcast, it returns the new gas price