Go to the source code of this file.
|
VOID | PhInitializeAvlTree (_Out_ PPH_AVL_TREE Tree, _In_ PPH_AVL_TREE_COMPARE_FUNCTION CompareFunction) |
| Initializes an AVL tree.
|
|
FORCEINLINE PPH_AVL_LINKS | PhpFindElementAvlTree (_In_ PPH_AVL_TREE Tree, _In_ PPH_AVL_LINKS Element, _Out_ PLONG Result) |
| Finds an element in an AVL tree.
|
|
FORCEINLINE VOID | PhpRotateLeftAvlLinks (_Inout_ PPH_AVL_LINKS *Root) |
|
FORCEINLINE VOID | PhpRotateLeftTwiceAvlLinks (_Inout_ PPH_AVL_LINKS *Root) |
|
FORCEINLINE VOID | PhpRotateRightAvlLinks (_Inout_ PPH_AVL_LINKS *Root) |
|
FORCEINLINE VOID | PhpRotateRightTwiceAvlLinks (_Inout_ PPH_AVL_LINKS *Root) |
|
ULONG | PhpRebalanceAvlLinks (_Inout_ PPH_AVL_LINKS *Root) |
|
PPH_AVL_LINKS | PhAddElementAvlTree (_Inout_ PPH_AVL_TREE Tree, _Out_ PPH_AVL_LINKS Element) |
| Adds an element to an AVL tree.
|
|
VOID | PhRemoveElementAvlTree (_Inout_ PPH_AVL_TREE Tree, _Inout_ PPH_AVL_LINKS Element) |
| Removes an element from an AVL tree.
|
|
PPH_AVL_LINKS | PhFindElementAvlTree (_In_ PPH_AVL_TREE Tree, _In_ PPH_AVL_LINKS Element) |
| Finds an element in an AVL tree.
|
|
PPH_AVL_LINKS | PhFindElementAvlTree2 (_In_ PPH_AVL_TREE Tree, _In_ PPH_AVL_LINKS Element, _Out_ PLONG Result) |
| Finds an element in an AVL tree.
|
|
PPH_AVL_LINKS | PhMinimumElementAvlTree (_In_ PPH_AVL_TREE Tree) |
| Finds the smallest element in an AVL tree.
|
|
PPH_AVL_LINKS | PhMaximumElementAvlTree (_In_ PPH_AVL_TREE Tree) |
| Finds the biggest element in an AVL tree.
|
|
PPH_AVL_LINKS | PhSuccessorElementAvlTree (_In_ PPH_AVL_LINKS Element) |
| Finds the next element in an AVL tree.
|
|
PPH_AVL_LINKS | PhPredecessorElementAvlTree (_In_ PPH_AVL_LINKS Element) |
| Finds the previous element in an AVL tree.
|
|
VOID | PhEnumAvlTree (_In_ PPH_AVL_TREE Tree, _In_ PH_TREE_ENUMERATION_ORDER Order, _In_ PPH_ENUM_AVL_TREE_CALLBACK Callback, _In_opt_ PVOID Context) |
| Enumerates the elements in an AVL tree.
|
|
Adds an element to an AVL tree.
- Parameters
-
Tree | The tree. |
Element | The element to add. |
- Returns
- NULL if the element was added, or an existing element.
Definition at line 492 of file collect.c.
Enumerates the elements in an AVL tree.
- Parameters
-
Tree | The tree. |
Order | The enumeration order. |
Callback | The callback function. |
Context | A user-defined value to pass to the callback function. |
Definition at line 894 of file collect.c.
Finds an element in an AVL tree.
- Parameters
-
Tree | The tree. |
Element | An element to find. |
- Returns
- The element, or NULL if it could not be found.
Definition at line 706 of file collect.c.
Finds an element in an AVL tree.
- Parameters
-
Tree | The tree. |
Element | The element to find. |
Result | The result of the search. |
- Returns
- The closest element, or NULL if the tree is empty.
Definition at line 731 of file collect.c.
VOID PhInitializeAvlTree |
( |
_Out_ PPH_AVL_TREE |
Tree, |
|
|
_In_ PPH_AVL_TREE_COMPARE_FUNCTION |
CompareFunction |
|
) |
| |
Initializes an AVL tree.
- Parameters
-
Tree | The tree. |
CompareFunction | A function used to compare tree elements. |
Definition at line 31 of file collect.c.
Finds the biggest element in an AVL tree.
- Parameters
-
- Returns
- An element, or NULL if the tree is empty.
Definition at line 781 of file collect.c.
Finds the smallest element in an AVL tree.
- Parameters
-
- Returns
- An element, or NULL if the tree is empty.
Definition at line 757 of file collect.c.
Finds an element in an AVL tree.
- Parameters
-
Tree | The tree. |
Element | The element to find. |
Result | The result of the search. |
Definition at line 52 of file collect.c.
Finds the previous element in an AVL tree.
- Parameters
-
- Returns
- The previous element, or NULL if there are no more elements.
Definition at line 848 of file collect.c.
Removes an element from an AVL tree.
- Parameters
-
Tree | The tree. |
Element | An element already present in the tree. |
Definition at line 577 of file collect.c.
Finds the next element in an AVL tree.
- Parameters
-
- Returns
- The next element, or NULL if there are no more elements.
Definition at line 806 of file collect.c.