frepple::utils::Tree Class Reference
This class implements a binary tree data structure. It is used as a container for entities keyed by their name. More...
#include <utils.h>
Inheritance diagram for frepple::utils::Tree:

Classes | |
| class | TreeNode |
| This class represents a node in the tree. More... | |
Public Types | |
| enum | NodeColor { red, black, none } |
Public Member Functions | |
| TreeNode * | begin () const |
| void | clear () |
| bool | empty () const |
| TreeNode * | end () const |
| void | erase (TreeNode *x) |
| TreeNode * | find (const string &k) const |
| TreeNode * | findLowerBound (const string &k, bool *f) const |
| TreeNode * | insert (TreeNode *v) |
| TreeNode * | insert (TreeNode *v, TreeNode *hint) |
| void | rename (TreeNode *obj, string newname) |
| size_t | size () const |
| Tree (bool b=false) | |
| void | verify () const |
| ~Tree () | |
Detailed Description
This class implements a binary tree data structure. It is used as a container for entities keyed by their name.
Technically, the data structure can be described as a red-black tree with intrusive tree nodes.
- See also:
- HasName
Member Enumeration Documentation
Constructor & Destructor Documentation
| frepple::utils::Tree::Tree | ( | bool | b = false | ) | [inline] |
| frepple::utils::Tree::~Tree | ( | ) | [inline] |
Member Function Documentation
| TreeNode* frepple::utils::Tree::begin | ( | ) | const [inline] |
| void frepple::utils::Tree::clear | ( | ) |
| bool frepple::utils::Tree::empty | ( | ) | const [inline] |
| TreeNode* frepple::utils::Tree::end | ( | ) | const [inline] |
| void frepple::utils::Tree::erase | ( | TreeNode * | x | ) |
| TreeNode* frepple::utils::Tree::find | ( | const string & | k | ) | const [inline] |
| TreeNode* frepple::utils::Tree::findLowerBound | ( | const string & | k, |
| bool * | f | ||
| ) | const [inline] |
| Tree::TreeNode * frepple::utils::Tree::insert | ( | TreeNode * | v, |
| TreeNode * | hint | ||
| ) |
| void frepple::utils::Tree::rename | ( | TreeNode * | obj, |
| string | newname | ||
| ) | [inline] |
| size_t frepple::utils::Tree::size | ( | ) | const [inline] |
| void frepple::utils::Tree::verify | ( | ) | const |
The documentation for this class was generated from the following files:
Documentation generated for frePPLe by
