Trait TryDatabaseCommit

Source
pub trait TryDatabaseCommit {
    type Error: Error;

    // Required method
    fn try_commit(
        &mut self,
        changes: HashMap<Address, Account>,
    ) -> Result<(), Self::Error>;
}
Expand description

EVM database commit interface that can fail.

This is intended for use with types that may fail to commit changes, e.g. because they are directly interacting with the filesystem, or must arrange access to a shared resource.

Required Associated Types§

Source

type Error: Error

Error type for when TryDatabaseCommit::try_commit fails.

Required Methods§

Source

fn try_commit( &mut self, changes: HashMap<Address, Account>, ) -> Result<(), Self::Error>

Attempt to commit changes to the database.

Implementations on Foreign Types§

Source§

impl<Db> TryDatabaseCommit for Arc<Db>
where Db: DatabaseCommit + Send + Sync,

Source§

type Error = ArcUpgradeError

Source§

fn try_commit( &mut self, changes: HashMap<Address, Account>, ) -> Result<(), Self::Error>

Implementors§