logos.std.data.persistent.bt.cow
Module std · package logos-std
Types
structBranchNode
struct BranchNode
Implements: BTreeNode
Fields
base: NodeBase<STORE_CFG>
children: Vec<Arc<dyn BTreeNode>>
keys: Buffer<K>
subtree_size: PrimVec<u64>
structLeafDirNode
struct LeafDirNode
Directory-leaf node: vals are NodeARC handles to child container roots, not raw data.
Implements: BTreeNode
Fields
base: NodeBase<STORE_CFG>
Holds the common node header (id, snapshot_id, is_leaf, block_code).
keys: Buffer<K>
Stores the sorted keys, parallel to vals.
vals: Vec<Arc<dyn BTreeNode>>
Stores NodeARC handles to child container roots, parallel to keys.
structLeafNode
struct LeafNode
Data-leaf node: keys and vals are parallel Buffers of container data, no NodeARC children.
Implements: BTreeNode
Fields
base: NodeBase<STORE_CFG>
Holds the common node header (id, snapshot_id, is_leaf, block_code).
keys: Buffer<K>
Stores the sorted keys, parallel to vals.
vals: Buffer<V>
Stores the values, parallel to keys.
structLeafNodeForBranch
struct LeafNodeForBranch
Seeds #[derive_branch_node], which emits BranchNode from this struct’s type params.
Not used as a node type itself; the emitted branch carries keys, children, and one
aggregate column per BRANCH_OPS op (subtree_size: PrimVec<u64>).
Fields
base: NodeBase<STORE_CFG>
Holds the common node header (id, snapshot_id, is_leaf, block_code).
keys: Buffer<K>
Stores the sorted keys, parallel to vals.
vals: Buffer<V>
Stores the values, parallel to keys.
Functions
fnbranch_alloc
fn branch_alloc(id: <cfg-slot-type>, snapshot_id: <cfg-slot-type>) -> Arc<dyn BTreeNode>
Allocates a new BranchNode and returns it wrapped as a NodeARC.
BranchNode is macro-derived with no struct-literal form, so this builds the control
block uninitialised and fills the node fields in place through a raw pointer.
fnbranchnode_subtree_size_shuttle
fn branchnode_subtree_size_shuttle(br: *const BranchNode<K, STORE_CFG, CFG>, target: u64) -> ShuttleResult
fnleaf_alloc
fn leaf_alloc(id: <cfg-slot-type>, snapshot_id: <cfg-slot-type>) -> Arc<dyn BTreeNode>
Builds a LeafNode struct literal and moves it into a fresh NodeARC.
fnleaf_dir_alloc
fn leaf_dir_alloc(id: <cfg-slot-type>, snapshot_id: <cfg-slot-type>) -> Arc<dyn BTreeNode>
Builds a LeafDirNode struct literal and moves it into a fresh NodeARC.