Main Page   Class Hierarchy   File List  

TreeNode.h

00001 #ifndef TREENODE_H
00002 #define TREENODE_H
00003 #include <vector>
00004 #include <string>
00005 
00006 class TreeNode {
00007         public:
00008                 TreeNode(string name,string value,vector<TreeNode *> * childVec);
00009                 TreeNode(string name,string value);
00010                 TreeNode();
00011                 vector<TreeNode*> * children;   
00012                 //vector<TreeNode*>  children;  
00013                 string name;
00014                 string value;
00015                 vector<TreeNode*> * getChildren(); 
00016                 string getName();
00017                 string getValue();
00018                 TreeNode * getChild(const string & name); //gets Children throws a string * exception
00019                                                           //get the 1st Child
00020                                                           //with that name
00021                 bool existChild(const string & name); //Does a subchild exist?
00022                 virtual ~TreeNode();
00023                 void clearChildren();
00024         private:
00025                 void init(string name,string value,vector<TreeNode*> * vecChild);
00026 
00027 };
00028 #endif

Generated on Sat Dec 7 21:28:09 2002 by doxygen1.2.18