penumbra_fee::component

Trait FeePay

Source
pub trait FeePay: StateWrite {
    // Provided method
    fn pay_fee<'life0, 'async_trait>(
        &'life0 mut self,
        gas_used: Gas,
        fee: Fee,
    ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
       where Self: Send + 'async_trait,
             'life0: 'async_trait { ... }
}
Available on crate feature component only.
Expand description

Allows payment of transaction fees.

Provided Methods§

Source

fn pay_fee<'life0, 'async_trait>( &'life0 mut self, gas_used: Gas, fee: Fee, ) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: Send + 'async_trait, 'life0: 'async_trait,

Uses the provided fee to pay for gas_used, erroring if the fee is insufficient.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<S: StateWrite + ?Sized> FeePay for S