enum lfds710_btree_au_absolute_position
Jump to navigation
Jump to search
Source File
└───liblfds710 └───inc └───liblfds710 lfds710_btree_addonly_unbalanced.h
Enum
enum lfds710_btree_au_absolute_position { LFDS710_BTREE_AU_ABSOLUTE_POSITION_ROOT, LFDS710_BTREE_AU_ABSOLUTE_POSITION_SMALLEST_IN_TREE, LFDS710_BTREE_AU_ABSOLUTE_POSITION_LARGEST_IN_TREE };
Values
LFDS710_BTREE_AU_ABSOLUTE_POSITION_ROOT
- Indicate the root element of the tree - the physical root, i.e. the first element linked into the tree. The root element has no particular or noteworthy logical value.
LFDS710_BTREE_AU_ABSOLUTE_POSITION_SMALLEST_IN_TREE
- Indicates the smallest element of tree (the leftmost element from the root).
LFDS710_BTREE_AU_ABSOLUTE_POSITION_LARGEST_IN_TREE
- Indicates the largest element of tree (the rightmost element from the root).
Notes
Used by lfds710_btree_au_get_by_absolute_position and lfds710_btree_au_get_by_absolute_position_and_then_by_relative_position to select an element from a btree.
An inorder walk, from smallest to largest, is performed by getting LFDS710_BTREE_AU_ABSOLUTE_POSITION_SMALLEST_IN_TREE and then repeatedly following the direction LFDS710_BTREE_AU_RELATIVE_POSITION_NEXT_LARGER_ELEMENT_IN_ENTIRE_TREE. (Flip the SMALLEST and LARGEST to walk from largest to smallest.)