Rabbit Tree
Radix bit tries for implementing associative arrays and sets in C.
|
Rabbit Tree node type. More...
#include <node.h>
Data Fields | |
RBT_KEY_SIZE_T | bits |
Number of significant bits in the key. More... | |
RBT_PIN_T * | key |
Key segment associated with this node. More... | |
struct RBT_NODE_T * | left |
Left child node. More... | |
struct RBT_NODE_T * | right |
Right child node. More... | |
RBT_VALUE_T | value |
Value associated with the node. More... | |
Rabbit Tree node type.
RBT_KEY_SIZE_T RBT_NODE_T::bits |
Number of significant bits in the key.
If a node has no children then all of the bits in its key are significant, otherwise all bits until the first bit that differs between the child node keys.
RBT_PIN_T* RBT_NODE_T::key |
Key segment associated with this node.
The key is a pointer to an array of unsigned integers. The type of the integers is determined by the RBT_PIN_T macro.
struct RBT_NODE_T* RBT_NODE_T::left |
Left child node.
The first additional significant bit of this child is 0.
struct RBT_NODE_T* RBT_NODE_T::right |
Right child node.
The first additional significant bit of this child is 1.
RBT_VALUE_T RBT_NODE_T::value |
Value associated with the node.
The value is considered empty if RBT_VALUE_IS_NULL returns non-zero.