#include <TreeNode.h>
TreeNode is used for XML Parsing output.
Definition at line 8 of file TreeNode.h.
Public Methods | |
TreeNode (string name, string value, vector< TreeNode * > *childVec) | |
TreeNode (string name, string value) | |
TreeNode () | |
vector< TreeNode * > * | getChildren () |
getChildren Returns a list of child nodes. | |
string | getName () |
Returns the name of the treeNode. | |
string | getValue () |
Returns the value of the treeNode. | |
TreeNode * | getChild (const string &name) |
getChild gets the 1st Child with the node name name, throws an string * exception if the node is not found | |
bool | existChild (const string &name) |
Does a child by name exist? | |
virtual | ~TreeNode () |
Destructor. | |
void | clearChildren () |
remove all children | |
Public Attributes | |
vector< TreeNode * > * | children |
list of Child nodes | |
string | name |
the name of the TreeNode | |
string | value |
it's value | |
Private Methods | |
void | init (string name, string value, vector< TreeNode * > *vecChild) |
|
Definition at line 3 of file TreeNode.C. |
|
Definition at line 6 of file TreeNode.C. |
|
Definition at line 9 of file TreeNode.C. References init(). |
|
Destructor.
Definition at line 21 of file TreeNode.C. References children, and clearChildren(). |
|
remove all children
Definition at line 66 of file TreeNode.C. References children. Referenced by parseXML(), and ~TreeNode(). |
|
Does a child by name exist?
Definition at line 51 of file TreeNode.C. References children, and name. Referenced by MessageExecutor::executeMessage(). |
|
getChild gets the 1st Child with the node name name, throws an string * exception if the node is not found
Definition at line 38 of file TreeNode.C. References children, and name. Referenced by MessageExecutor::executeMessage(), and mainTest(). |
|
getChildren Returns a list of child nodes.
Definition at line 63 of file TreeNode.C. References children. Referenced by traverseTree(). |
|
Returns the name of the treeNode.
Definition at line 73 of file TreeNode.C. References name. |
|
Returns the value of the treeNode.
Definition at line 74 of file TreeNode.C. References value. Referenced by MessageExecutor::executeMessage(), mainTest(), and traverseTree(). |
|
Definition at line 12 of file TreeNode.C. References children, name, and value. Referenced by TreeNode(). |
|
list of Child nodes
Definition at line 16 of file TreeNode.h. Referenced by clearChildren(), existChild(), getChild(), getChildren(), init(), parseXML(), and ~TreeNode(). |
|
the name of the TreeNode
Definition at line 20 of file TreeNode.h. Referenced by existChild(), getChild(), getName(), init(), and TreeNode(). |
|
it's value
Definition at line 24 of file TreeNode.h. Referenced by getValue(), init(), parseXML(), and TreeNode(). |