Trait parity_machine::WithBalances[][src]

pub trait WithBalances: Machine {
    fn balance(
        &self,
        live: &Self::LiveBlock,
        address: &Address
    ) -> Result<U256, Self::Error>;
fn add_balance(
        &self,
        live: &mut Self::LiveBlock,
        address: &Address,
        amount: &U256
    ) -> Result<(), Self::Error>; }

A state machine that uses balances.

Required Methods

Get the balance, in base units, associated with an account. Extracts data from the live block.

Increment the balance of an account in the state of the live block.

Implementors