Lines Matching full:tree

2  * rbtree.h -- generic red-black tree
39 * Red black tree. Implementation taken from NSD 3.0.5, adjusted for use
73 /** An entire red black tree */
75 /** definition for tree struct */
77 /** The root of the red-black tree */
80 /** The number of the nodes in the tree */
91 * Create new tree (malloced) with given key compare function.
93 * @return: new tree, empty.
98 * Init a new tree (malloced by caller) with given key compare function.
99 * @param rbtree: uninitialised memory for new tree, returned empty.
105 * Insert data into the tree.
106 * @param rbtree: tree to insert to.
113 * Delete element from tree.
114 * @param rbtree: tree to delete from.
116 * @return: node that is now unlinked from the tree. User to delete it.
122 * Find key in tree. Returns NULL if not found.
123 * @param rbtree: tree to find in.
131 * @param rbtree: tree to find in.
134 * precedes the position of key in the tree. NULL if no smaller element.
142 * Returns first (smallest) node in the tree
143 * @param rbtree: tree
144 * @return: smallest element or NULL if tree empty.
149 * Returns last (largest) node in the tree
150 * @param rbtree: tree
151 * @return: largest element or NULL if tree empty.
156 * Returns next larger node in the tree
157 * @param rbtree: tree
158 * @return: next larger element or NULL if no larger in tree.
163 * Returns previous smaller node in the tree
164 * @param rbtree: tree
165 * @return: previous smaller element or NULL if no previous in tree.
179 * Call function for all elements in the redblack tree, such that
182 * Note that your function must not remove the nodes from the tree.
184 * @param tree: the tree
189 void traverse_postorder(rbtree_type* tree, void (*func)(rbnode_type*, void*),