Trait reth_trie::hashed_cursor::HashedCursor

source ·
pub trait HashedCursor {
    type Value: Debug;

    // Required methods
    fn seek(
        &mut self,
        key: B256,
    ) -> Result<Option<(B256, Self::Value)>, DatabaseError>;
    fn next(&mut self) -> Result<Option<(B256, Self::Value)>, DatabaseError>;
}
Expand description

The cursor for iterating over hashed entries.

Required Associated Types§

source

type Value: Debug

Value returned by the cursor.

Required Methods§

source

fn seek( &mut self, key: B256, ) -> Result<Option<(B256, Self::Value)>, DatabaseError>

Seek an entry greater or equal to the given key and position the cursor there. Returns the first entry with the key greater or equal to the sought key.

source

fn next(&mut self) -> Result<Option<(B256, Self::Value)>, DatabaseError>

Move the cursor to the next entry and return it.

Implementors§

source§

impl<'a, C> HashedCursor for HashedPostStateAccountCursor<'a, C>
where C: HashedCursor<Value = Account>,

source§

type Value = Account

source§

impl<'a, C> HashedCursor for HashedPostStateStorageCursor<'a, C>
where C: HashedStorageCursor<Value = U256>,

source§

type Value = Uint<256, 4>