referrerpolicy=no-referrer-when-downgrade
snowbridge_outbound_queue_primitives::v1::message

Trait GasMeter

Source
pub trait GasMeter {
    const MAXIMUM_BASE_GAS: u64;

    // Required method
    fn maximum_dispatch_gas_used_at_most(command: &Command) -> u64;

    // Provided method
    fn maximum_gas_used_at_most(command: &Command) -> u64 { ... }
}

Required Associated Constants§

Source

const MAXIMUM_BASE_GAS: u64

All the gas used for submitting a message to Ethereum, minus the cost of dispatching the command within the message

Required Methods§

Source

fn maximum_dispatch_gas_used_at_most(command: &Command) -> u64

Measures the maximum amount of gas a command payload will require to dispatch, NOT including validation & verification.

Provided Methods§

Source

fn maximum_gas_used_at_most(command: &Command) -> u64

Total gas consumed at most, including verification & dispatch

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.

Implementations on Foreign Types§

Source§

impl GasMeter for ()

Implementors§