pub struct AccountDB<'db> { /* private fields */ }
Expand description
DB backend wrapper for Account trie Transforms trie node keys for the database
Implementations§
Trait Implementations§
Source§impl<'db> AsHashDB<KeccakHasher, Vec<u8>> for AccountDB<'db>
impl<'db> AsHashDB<KeccakHasher, Vec<u8>> for AccountDB<'db>
Source§fn as_hash_db(&self) -> &dyn HashDB<KeccakHasher, DBValue>
fn as_hash_db(&self) -> &dyn HashDB<KeccakHasher, DBValue>
Perform upcast to HashDB for anything that derives from HashDB.
Source§fn as_hash_db_mut(&mut self) -> &mut dyn HashDB<KeccakHasher, DBValue>
fn as_hash_db_mut(&mut self) -> &mut dyn HashDB<KeccakHasher, DBValue>
Perform mutable upcast to HashDB for anything that derives from HashDB.
Source§impl<'db> HashDB<KeccakHasher, Vec<u8>> for AccountDB<'db>
impl<'db> HashDB<KeccakHasher, Vec<u8>> for AccountDB<'db>
Source§fn get(&self, key: &H256, prefix: Prefix<'_>) -> Option<DBValue>
fn get(&self, key: &H256, prefix: Prefix<'_>) -> Option<DBValue>
Look up a given hash into the bytes that hash to it, returning None if the
hash is not known.
Source§fn contains(&self, key: &H256, prefix: Prefix<'_>) -> bool
fn contains(&self, key: &H256, prefix: Prefix<'_>) -> bool
Check for the existence of a hash-key.
Source§fn insert(&mut self, _prefix: Prefix<'_>, _value: &[u8]) -> H256
fn insert(&mut self, _prefix: Prefix<'_>, _value: &[u8]) -> H256
Insert a datum item into the DB and return the datum’s hash for a later lookup. Insertions
are counted and the equivalent number of
remove()
s must be performed before the data
is considered dead.Auto Trait Implementations§
impl<'db> Freeze for AccountDB<'db>
impl<'db> !RefUnwindSafe for AccountDB<'db>
impl<'db> Send for AccountDB<'db>
impl<'db> Sync for AccountDB<'db>
impl<'db> Unpin for AccountDB<'db>
impl<'db> !UnwindSafe for AccountDB<'db>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more