The type stored in the tree.
The type used by search functions, but that cannot be added to
the tree. It defaults to T
.
The compare function to use to sort the tree.
A method designed mostly for internal use that finds the next element in the tree if all of the elements were placed in order.
The object or search type to find the successor of
The node in the tree where the search can be started. It's optional and does not need to be changed for nearly all use cases.
Add an element to the tree.
The object to add to the tree.
The node in the tree where the search can be started. It's optional and does not need to be changed for nearly all use cases.
Get all the objects greater than or equal to an object or search type.
The search type or object at which to start a search.
Get all the objects less than or equal to an object or search type.
The search type or object at which to end a search.
Get all the objects in a range.
The search type or object at which to start a search.
The search type or object at which to end a search
inclusively. The name is endm1
to stand for END Minus 1
since the
search is performed inclusively.
Perform an operation on all nodes.
The function to run on each node.
If true, operation
will be called sequentially. If
false, operation
will be called for the root node first, then children.
The node in the tree where the search can be started. It's optional and does not need to be changed for nearly all use cases.
Perform an operation on all of the elements greater than or equal to a search type or object.
The search type or object at which to start a search.
The function to run on each node.
If true, operation
will be called sequentially. If
false, operation
will be called for the root node first, then children.
The node in the tree where the search can be started. It's optional and does not need to be changed for nearly all use cases.
Perform an operation on all of the elements less than or equal to a search type or object.
The search type or object at which to end a search.
The function to run on each node.
If true, operation
will be called sequentially. If
false, operation
will be called for the root node first, then children.
The node in the tree where the search can be started. It's optional and does not need to be changed for nearly all use cases.
Perform an operation on all of the elements in a range.
The search type or object at which to start a search.
The search type or object at which to end a search
inclusively. The name is endm1
to stand for END Minus 1
since the
search is performed inclusively.
The function to run on each node.
The node in the tree where the search can be started. It's optional and does not need to be changed for nearly all use cases.
TODO: Fix
Remove an element from the tree.
The object to remove or a search type that is evaluated to the same value as an object in the tree. Equivalence is determined exclusively using the compare function.
An optional function that has the final say in whether a
node is removed. While an object
is provided for quick tree traversal, it
is not always desirable to remove every node with that particular value.
This function allows the user to override that behavior.
The node in the tree where the search can be started. It's optional and does not need to be changed for nearly all use cases.
Generated using TypeDoc
A binary search tree implementation for finding ranges within the tree and finding neighboring nodes.