MCPcopy Create free account
hub / github.com/carsonpo/haystackdb / new_internal

Method new_internal

src/structures/mmap_tree/node.rs:58–69  ·  view source on GitHub ↗
(offset: usize)

Source from the content-addressed store, hash-verified

56 }
57
58 pub fn new_internal(offset: usize) -> Self {
59 Node {
60 keys: Vec::new(),
61 values: Vec::new(),
62 children: Vec::new(),
63 max_keys: MAX_KEYS,
64 node_type: NodeType::Internal,
65 offset,
66 is_root: false,
67 parent_offset: Some(0),
68 }
69 }
70
71 pub fn split(&mut self, b: usize) -> Result<(K, Node<K, V>), io::Error> {
72 // println!("Splitting node: {:?}", self.keys);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected