Trait reth_trie::hashed_cursor::HashedCursorFactory

source ·
pub trait HashedCursorFactory {
    type AccountCursor: HashedCursor<Value = Account>;
    type StorageCursor: HashedStorageCursor<Value = U256>;

    // Required methods
    fn hashed_account_cursor(
        &self,
    ) -> Result<Self::AccountCursor, DatabaseError>;
    fn hashed_storage_cursor(
        &self,
        hashed_address: B256,
    ) -> Result<Self::StorageCursor, DatabaseError>;
}
Expand description

The factory trait for creating cursors over the hashed state.

Required Associated Types§

source

type AccountCursor: HashedCursor<Value = Account>

The hashed account cursor type.

source

type StorageCursor: HashedStorageCursor<Value = U256>

The hashed storage cursor type.

Required Methods§

source

fn hashed_account_cursor(&self) -> Result<Self::AccountCursor, DatabaseError>

Returns a cursor for iterating over all hashed accounts in the state.

source

fn hashed_storage_cursor( &self, hashed_address: B256, ) -> Result<Self::StorageCursor, DatabaseError>

Returns a cursor for iterating over all hashed storage entries in the state.

Implementors§