The type of the nodes in the tree.
Public Member Functions | |
| Node (index_type l=0, index_type r=0, node_index_type parent=UNDEFINED) | |
| Construct a node from left most index, right most index, and parent. | |
| Node (Node &&)=default | |
| Default move constructor. | |
| Node (Node const &)=default | |
| Default copy constructor. | |
| node_index_type & | child (letter_type c) |
| The index of the child node corresponding to a letter (if any). | |
| node_index_type | child (letter_type c) const |
| The index of the child node corresponding to a letter (if any). | |
| bool | is_leaf () const noexcept |
Returns true if the node is a leaf and false if not. | |
| bool | is_root () const noexcept |
Returns true if the node is the root and false if not. | |
| size_t | length () const noexcept |
| The length of the edge leading into the current node. | |
| Node & | operator= (Node &&)=default |
| Default move assignment. | |
| Node & | operator= (Node const &)=default |
| Default copy assignment. | |
|
explicit |
Construct a node from left most index, right most index, and parent.
| l | the left most index and value of the data member l (defaults to 0). |
| r | one after the right most index and value of the data member r (defaults to 0). |
| parent | of the node being constructed (defaults to UNDEFINED). |
| node_index_type & child | ( | letter_type | c | ) |
The index of the child node corresponding to a letter (if any).
| c | the first letter in the edge of the node. |
size_t.children.size(). | node_index_type child | ( | letter_type | c | ) | const |
The index of the child node corresponding to a letter (if any).
| c | the first letter in the edge of the node. |
size_t.children.size().
|
inlinenoexcept |
Returns true if the node is a leaf and false if not.
bool.noexcept and is guaranteed never to throw.
|
inlinenoexcept |
Returns true if the node is the root and false if not.
bool.noexcept and is guaranteed never to throw.
|
inlinenoexcept |
The length of the edge leading into the current node.
size_t.noexcept and is guaranteed never to throw.
|
mutable |
The children of the current node.
The index of the first letter in the edge leading to the node.
| node_index_type parent |
The index of the parent node.
The index of one past the last letter in the edge leading to the node.