﻿ RedBlackTree(T) Methods

The RedBlackTreeT generic type exposes the following members.

Methods
NameDescription
Adds a new item to the tree. If the element already belongs to this tree, no new element will be added.
Adds a new item to the tree. If the element already belongs to this tree, no new element will be added.
Clear
Removes all nodes from the tree.
Contains(T)
Determines whether this tree contains the specified item.
Contains(RedBlackTreeNodeT)
Determines whether this tree contains the specified item.
CopyTo(T, Int32)
Copies the elements of this tree to an array, starting at a particular arrayIndex.
CopyTo(RedBlackTreeNodeT, Int32)
Copies the nodes of this tree to an array, starting at a particular arrayIndex.
Equals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Finalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Find
Attempts to find a node that contains the specified key.
FindGreaterThan(T)
Finds the smallest point in the in the tree that is greater than (>) k. In other words, finds a number stored in the tree that is immediately above k.
FindGreaterThan(RedBlackTreeNodeT, T)
Finds the smallest point in the subtree rooted at node that is greater than (>) k. In other words, finds a number stored in the tree that is immediately above k.
FindLessThan(T)
Finds the greatest point in the tree that is less than (<) k. In other words, finds a number stored in the tree that is immediately below k.
FindLessThan(RedBlackTreeNodeT, T)
Finds the greatest point in the subtree rooted at node that is less than (<) k. In other words, finds a number stored in the tree that is immediately below k.
FindLessThanOrEqualTo(T)
Finds the greatest point in the tree that is less than or equal to (<=) k. In other words, finds either k or a number immediately below it.
FindLessThanOrEqualTo(RedBlackTreeNodeT, T)
Finds the greatest point in the subtree rooted at node that is less than or equal to (<=) k. In other words, finds either k or a number immediately below it.
GetEnumerator
Returns an enumerator that iterates through this tree in-order.
(Overrides BinaryTreeTNodeGetEnumerator.)
GetHashCode
Serves as the default hash function.
(Inherited from Object.)
GetNextNode
Gets the node that contains the next in-order value coming after the value contained in the given node.
GetPreviousNode
Gets the node that contains the previous in-order value coming before the value contained in the given node.
GetType
Gets the Type of the current instance.
(Inherited from Object.)
Max
Finds the maximum element stored in the tree.
MemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Min
Finds the minimum element stored in the tree.
Remove(T)
Removes a node from the tree.
Remove(RedBlackTreeNodeT)
Removes a node from the tree.
Resort
Forces a re-balance of the tree by removing and inserting the same node.
ToString
Returns a string that represents the current object.
(Inherited from Object.)
Traverse
Traverse the tree using a tree traversal method. Can be iterated with a foreach loop.
(Inherited from BinaryTreeTNode.)
Top
Extension Methods
NameDescription
HasMethod
Checks whether an object implements a method with the given name.
(Defined by ExtensionMethods.)
IsEqual
Compares two objects for equality, performing an elementwise comparison if the elements are vectors or matrices.
(Defined by Matrix.)