Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/base/triedb
/ functions
Functions
627 in github.com/base/triedb
⨍
Functions
627
◇
Types & classes
91
↓ 6 callers
Method
get_slot
Returns the 64 nibble storage trie portion of the storage path.
src/path.rs:371
↓ 6 callers
Method
has_children
Returns whether the [Node] type supports children.
src/node.rs:156
↓ 6 callers
Method
num_free_bytes
(&self)
src/page/slotted_page.rs:71
↓ 6 callers
Method
pop
Reclaims a page from the orphan page list. The returned page (if any) is guaranteed to have been orphaned at `snapshot_threshold` or earlier. This m
src/meta/mod.rs:683
↓ 6 callers
Method
sub_slice_for_prefix
Creates a zero-copy sub-slice containing only changes that affect the subtree rooted at the given path prefix. This is used during recursive trie trav
src/overlay.rs:308
↓ 6 callers
Method
update_node_child
Updates a node's child pointer, handling both setting and removal.
src/storage/engine/handlers.rs:681
↓ 6 callers
Method
with_prefix_offset
Creates a new OverlayState with a prefix offset applied. This is used for storage trie traversal where we want to strip the account prefix (64 nibbles
src/overlay.rs:186
↓ 5 callers
Method
add_leaf
(&mut self, key: Nibbles, value: &[u8])
src/storage/overlay_root.rs:108
↓ 5 callers
Method
close
(self)
src/database.rs:183
↓ 5 callers
Method
first
(&self)
src/overlay.rs:141
↓ 5 callers
Function
generate_storage_paths_values
( addresses: &[AddressPath], storage_per_address: usize, )
benches/benchmark_common.rs:121
↓ 5 callers
Method
get_account_with_proof
Retrieves an [AccountProof] from the storage engine, identified by the given [AddressPath]. Returns [None] if the path is not found.
src/storage/proofs.rs:41
↓ 5 callers
Method
get_mut
Retrieves a mutable page from the memory mapped file.
src/page/manager/mmap.rs:206
↓ 5 callers
Method
lookup
Looks up a specific path in the overlay. Returns Some(value) if found, None if not in overlay. The path is adjusted by the prefix_offset before lookup
src/overlay.rs:168
↓ 5 callers
Method
pop
(&mut self)
src/storage/overlay_root.rs:66
↓ 5 callers
Method
push_node
( &mut self, path: RawPath, node: Node, page: Rc<SlottedPage<'a>>, ove
src/storage/overlay_root.rs:37
↓ 5 callers
Method
set_cell_pointer
Sets the cell pointer at the given index.
src/page/slotted_page.rs:417
↓ 5 callers
Method
snapshot_id
(&self)
src/meta/mod.rs:138
↓ 4 callers
Method
actual_orphans_range
(&self)
src/meta/mod.rs:217
↓ 4 callers
Method
as_offset
(&self)
src/page.rs:112
↓ 4 callers
Function
begin_rw
( db: DB, )
src/database.rs:278
↓ 4 callers
Function
builder
A wrapper around [`ThreadPoolBuilder::new()`] which sets some default values to make the resulting [`ThreadPool`] play nicely with the [`Executor`] tr
src/executor/threadpool.rs:7
↓ 4 callers
Method
child
(&self, _index: u8)
src/page/subtrie_page.rs:82
↓ 4 callers
Method
complete
(&self, value: T)
src/executor/futures.rs:47
↓ 4 callers
Method
create
Sets the option to create a new database, or open it if it already exists. The semantics of this method are equivalent to [`std::fs::OpenOptions::cre
src/database.rs:57
↓ 4 callers
Method
create_new
Sets the option to create a new database, failing if it already exists. The semantics of this method are equivalent to [`std::fs::OpenOptions::create
src/database.rs:68
↓ 4 callers
Method
direct_child
Returns the direct child of the [Node]. # Panics This function will panic if the [Node] is not an account leaf.
src/node.rs:208
↓ 4 callers
Function
encode_branch
(children: &[Option<Pointer>], out: &mut dyn BufMut)
src/node.rs:661
↓ 4 callers
Method
get
Retrieves a page from the memory mapped file.
src/page/manager/mmap.rs:191
↓ 4 callers
Function
get_content_index
(cell_index: u8)
src/page/slotted_page.rs:36
↓ 4 callers
Method
get_slotted_page
Retrieves a read-only [SlottedPage] from the underlying [PageManager].
src/storage/engine/page_ops.rs:129
↓ 4 callers
Method
orphan_page
Mark a given page as no longer in use (orphan). Orphaned pages can be reused for new allocations once the snapshot that orphaned them is no longer ac
src/storage/engine/page_ops.rs:90
↓ 4 callers
Method
page_count
(&self)
src/meta/mod.rs:165
↓ 4 callers
Method
parts_mut
(&mut self)
src/meta/mod.rs:465
↓ 4 callers
Method
prefix
Returns the prefix of the [Node].
src/node.rs:129
↓ 4 callers
Method
rlp_encode
Returns the RLP encoding of the [Node].
src/node.rs:289
↓ 4 callers
Method
sync
Saves the metadata to the storage device.
src/meta/mod.rs:587
↓ 4 callers
Method
verify_integrity
Checks if the metadata is not corrupted.
src/meta/mod.rs:253
↓ 3 callers
Method
commit_internal
(&mut self)
src/page/page.rs:290
↓ 3 callers
Method
compare_exchange
( &self, current: PageState, new: PageState, )
src/page/state.rs:105
↓ 3 callers
Method
compute_root_with_overlay
( &'a self, context: &TransactionContext, stack: &mut TraversalStack<'a>, root
src/storage/overlay_root.rs:159
↓ 3 callers
Method
dirty_slot
(&self)
src/meta/mod.rs:432
↓ 3 callers
Method
dirty_slot_mut
(&mut self)
src/meta/mod.rs:443
↓ 3 callers
Method
get_mut_clone
Retrieves a mutable clone of a [Page] from the underlying [PageManager]. This implements copy-on-write semantics: if the page belongs to the current
src/storage/engine/page_ops.rs:104
↓ 3 callers
Method
get_storage_with_proof
Retrieves an [AccountProof] from the storage engine, containing the storage proof for the given [StoragePath]. Returns [None] if the path is not found
src/storage/proofs.rs:51
↓ 3 callers
Method
inc_pages_read
(&self)
src/metrics.rs:42
↓ 3 callers
Method
is_empty
(&self)
src/path.rs:59
↓ 3 callers
Method
is_empty
Returns true if the overlay is empty.
src/overlay.rs:65
↓ 3 callers
Method
nibbles_uninit_mut
(&mut self)
src/path.rs:75
↓ 3 callers
Method
num_free_bytes_with_cell_count
(&self, num_cells: u8)
src/page/slotted_page.rs:97
↓ 3 callers
Method
num_occupied_bytes
below functions added for debug statistics
src/page/slotted_page.rs:118
↓ 3 callers
Method
num_occupied_cells
(&self)
src/page/slotted_page.rs:128
↓ 3 callers
Method
populate_dirty_slot
Copies the contents of the active slot into the dirty slot, and increases the snapshot ID.
src/meta/mod.rs:482
↓ 3 callers
Method
raw_contents_mut
(&mut self)
src/page/page.rs:249
↓ 3 callers
Method
raw_orphan_pages
(&self)
src/meta/mod.rs:451
↓ 3 callers
Method
raw_state_mut
(&self)
src/page/page.rs:243
↓ 3 callers
Function
rewind
(mut f: &File)
src/page/manager/mmap.rs:425
↓ 3 callers
Method
root_node_page_id
(&self)
src/meta/mod.rs:156
↓ 3 callers
Method
serialize_into
(&self, buf: &mut [u8])
src/storage/value.rs:53
↓ 3 callers
Method
set_num_cells
Sets the number of cells in the page.
src/page/slotted_page.rs:431
↓ 3 callers
Method
set_prefix
Sets the prefix of the [Node]. # Panics This function will panic if the provided prefix is greater than 64 nibbles long.
src/node.rs:138
↓ 3 callers
Method
set_values_in_page
Applies changes to a specific page, handling page cloning and split retries. This function clones the page (copy-on-write) and attempts to apply chan
src/storage/engine/write.rs:81
↓ 3 callers
Method
size
Returns the number of pages currently stored in the file.
src/page/manager/mmap.rs:111
↓ 3 callers
Method
starts_with
(&self, other: &RawPath)
src/path.rs:125
↓ 3 callers
Method
unset_dirty
(&self)
src/page/state.rs:130
↓ 3 callers
Function
verify_account_proof
(proof: &AccountProof, root: B256)
src/storage/proofs.rs:333
↓ 3 callers
Method
wipe
Sets the option to erase the database if it gets successfully opened.
src/database.rs:74
↓ 2 callers
Method
add_account_leaf_to_root_builder
( &self, root_builder: &mut RootBuilder, path: RawPath, nonce_rlp: &ArrayVec<u
src/storage/overlay_root.rs:443
↓ 2 callers
Method
add_branch
(&mut self, key: Nibbles, value: B256, stored_in_database: bool)
src/storage/overlay_root.rs:112
↓ 2 callers
Method
add_storage_branch_updates
( &mut self, account: B256, updates: HashMap<Nibbles, BranchNodeCompact>, )
src/storage/overlay_root.rs:116
↓ 2 callers
Function
address_path_for_idx
(idx: u64)
src/storage/engine/tests.rs:1955
↓ 2 callers
Function
alive_page_ids
(db: &Database)
src/database.rs:501
↓ 2 callers
Method
allocate_cell_pointer
Allocates a cell pointer at the given index with the given length and returns the cell pointer.
src/page/slotted_page.rs:265
↓ 2 callers
Function
begin_ro
( db: DB, )
src/database.rs:270
↓ 2 callers
Method
begin_rw
(&mut self, snapshot_id: SnapshotId)
src/transaction/manager.rs:25
↓ 2 callers
Method
compare_with_offset
Helper method to compare a stored path with a target path, applying prefix_offset. Returns the comparison result of the offset-adjusted stored path vs
src/overlay.rs:252
↓ 2 callers
Method
create
Sets the option to create a new file, or open it if it already exists. The default is `true`.
src/page/manager/options.rs:33
↓ 2 callers
Method
data
(&self)
src/overlay.rs:127
↓ 2 callers
Method
defer
(&self, f: F)
src/executor/threadpool.rs:21
↓ 2 callers
Method
defragment
(&mut self, index: u8, additional_slot_length: u16)
src/page/slotted_page.rs:287
↓ 2 callers
Function
encode_account_leaf
( nonce_rlp: &ArrayVec<u8, 9>, balance_rlp: &ArrayVec<u8, 33>, code_hash: &B256, storage_root:
src/node.rs:640
↓ 2 callers
Method
finalize
(self)
src/storage/overlay_root.rs:124
↓ 2 callers
Method
find_end_index_with_prefix
Returns the first index of the effective slice immediately following the given prefix. This is used to find the end of a prefix range in the overlay.
src/overlay.rs:235
↓ 2 callers
Method
find_start_index_with_prefix
Returns the first index of the effective slice with the given nibbles prefix
src/overlay.rs:223
↓ 2 callers
Function
fmt_page
(name: &str, p: &Page<'_>, f: &mut fmt::Formatter<'_>)
src/page/page.rs:43
↓ 2 callers
Function
fmt_slotted_page
(name: &str, p: &SlottedPage<'_>, f: &mut fmt::Formatter<'_>)
src/page/slotted_page.rs:24
↓ 2 callers
Method
get_storage_proof_from_page
( &self, context: &TransactionContext, original_path: &RawPath, path_offset: u
src/storage/proofs.rs:229
↓ 2 callers
Method
get_storage_slot
( &mut self, storage_path: &StoragePath, )
src/transaction.rs:73
↓ 2 callers
Method
get_value
(&'v self, index: u8)
src/page/subtrie_page.rs:63
↓ 2 callers
Method
get_value_from_page
Retrieves a [TrieValue] from the given page or any of its descendants. This is the core recursive function for traversing the trie to find a value. I
src/storage/engine/read.rs:121
↓ 2 callers
Method
get_value_with_proof
( &self, context: &TransactionContext, path: impl Into<RawPath>, )
src/storage/proofs.rs:59
↓ 2 callers
Method
hash
(&self)
src/meta/mod.rs:225
↓ 2 callers
Method
inc
(&self)
src/page.rs:121
↓ 2 callers
Method
is_account_leaf
Returns whether the [Node] is an account leaf.
src/node.rs:161
↓ 2 callers
Method
max_pages
Sets the maximum number of pages that can be allocated to this file. The default is [`PageId::MAX`].
src/page/manager/options.rs:59
↓ 2 callers
Method
next_free_cell_index
Returns the index of the next free cell in the page, which may include deleted cells.
src/page/slotted_page.rs:237
↓ 2 callers
Method
open_temp_file
()
src/page/manager/mmap.rs:40
↓ 2 callers
Method
orphan_subtrie
Orphans a subtrie from the page, orphaning any pages that become fully unreferenced as a result. Unlike delete_subtrie, this doesn't delete individua
src/storage/engine/page_ops.rs:247
↓ 2 callers
Method
print_page
Prints the structure of a page or the entire database starting from the root.
src/storage/debug.rs:91
↓ 2 callers
Method
print_path
Prints information about a given TrieValue. Verbose option: writes information about nodes visited along the path to file Extra-verbose option: writes
src/storage/debug.rs:197
← previous
next →
101–200 of 627, ranked by callers