Skip to content

sgns::storage::trie::TrieBatch

#include <trie_batches.hpp>

Inherits from sgns::storage::face::Readable< Buffer, Buffer >, sgns::storage::face::Writeable< Buffer, Buffer >, sgns::storage::face::Iterable< Buffer, Buffer >

Inherited by sgns::storage::trie::EphemeralTrieBatch, sgns::storage::trie::PersistentTrieBatch, sgns::storage::trie::TopperTrieBatch

Public Functions

Name
~TrieBatch() override =default
virtual outcome::result< void > clearPrefix(const Buffer & prefix) =0

Additional inherited members

Public Functions inherited from sgns::storage::face::Readable< Buffer, Buffer >

Name
virtual ~Readable() =default
virtual outcome::result< V > get(const K & key) const =0
Get value by key.
virtual bool contains(const K & key) const =0
Returns true if given key-value binding exists in the storage.
virtual bool empty() const =0
Returns true if the storage is empty.

Public Functions inherited from sgns::storage::face::Writeable< Buffer, Buffer >

Name
virtual ~Writeable() =default
virtual outcome::result< void > put(const K & key, const V & value) =0
Store value by key.
virtual outcome::result< void > put(const K & key, V && value) =0
virtual outcome::result< void > remove(const K & key) =0
Remove value by key.

Public Functions inherited from sgns::storage::face::Iterable< Buffer, Buffer >

Name
virtual ~Iterable() =default
virtual std::unique_ptr< MapCursor< K, V > > cursor() =0
Returns new key-value iterator.

Public Functions Documentation

function ~TrieBatch

~TrieBatch() override =default

function clearPrefix

virtual outcome::result< void > clearPrefix(
    const Buffer & prefix
) =0

Reimplemented by: sgns::storage::trie::EphemeralTrieBatchImpl::clearPrefix, sgns::storage::trie::PersistentTrieBatchImpl::clearPrefix, sgns::storage::trie::TopperTrieBatchImpl::clearPrefix

Remove all trie entries which key begins with the supplied prefix


Updated on 2026-03-04 at 13:10:44 -0800