BST in-order iterator.
More...
BST in-order iterator.
Create BST in-order iterator.
If the tree being iterated is modified, correct behaviour of the iterator is not guaranteed (i.o.w. don't do it).
- Parameters
-
- Returns
- Returns a new BST iterator instance. If memory allocation fails, returns NULL and sets uproc_errno to UPROC_ENOMEM.
Obtain next key/value pair.
- Parameters
-
iter | BST iterator |
key | OUT: value of next key |
value | OUT: value of next item |
- Returns
- Returns 0 if an item was produced. If the iterator is exhausted, returns 1 and does not modify *key or *value. This function can not fail, so -1 is never returned.