MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / get

Method get

nodedb/src/engine/kv/slab.rs:89–92  ·  view source on GitHub ↗

Read data from a slot.

(&self, slot_idx: u32, len: usize)

Source from the content-addressed store, hash-verified

87
88 /// Read data from a slot.
89 fn get(&self, slot_idx: u32, len: usize) -> &[u8] {
90 let offset = slot_idx as usize * self.slot_size;
91 &self.buf[offset..offset + len]
92 }
93
94 /// Total memory consumed by this tier (backing buffer).
95 fn capacity_bytes(&self) -> usize {

Callers

nothing calls this directly

Calls 5

is_large_handleFunction · 0.85
decode_large_handleFunction · 0.85
decode_handleFunction · 0.85
expectMethod · 0.45
as_refMethod · 0.45

Tested by

no test coverage detected