Crate contigious_tree

Source
Expand description

Write and read tree graphs to and from contigious blocks of memory.

Structs§

Branches
Iterates over the individual root nodes of subtrees
LeI32
32 Bit signed integer stored in little endian byte order
TreeBuilder
Serializes a tree data structure in a depth first manner.
TreeSlice
Each subtree is contigious in memory and can borrowed independently similarly to a slice of bytes.
TreeVec
An owned tree, which is stored in contigious memory. Fast traversal and query times.
U8
8 Bit unsigned integer stored in little endian byte order

Traits§

Node
TreeVec is generic over the value types associated with each node. Furthermore it is also generic about the way these are serialized. E.g. A value type of i64 could be stored in little endian, big endian or a bitpacked representation. This allows us to adapt the tree to a wide variaty of usecases.

Type Aliases§

TreeSize
Used to store the binary sizes of TreeVecs and TreeSlices in bytes. This would usually be done utilizing usize, yet the size of usize is platform dependend. Since part of the appeal of a serializable tree data structure is to store it to a filesystem and load it, it seems beneficial to fix this to 64Bit on any platform to not introduce a dependency of the fileformat to the platform it has been generated on.