diff options
author | An-Cheng Huang <ancheng@vyatta.com> | 2010-11-12 19:12:53 -0800 |
---|---|---|
committer | An-Cheng Huang <ancheng@vyatta.com> | 2010-11-12 19:12:53 -0800 |
commit | 79a94470b0f3fd4f7924bb096c61b8e064b65750 (patch) | |
tree | 049225edbd21f873b9a4bcac6571603a35aa1e89 /src/cnode/cnode.hpp | |
parent | e08c1879028ddd3b594b01c82859f8431894f497 (diff) | |
download | vyatta-cfg-79a94470b0f3fd4f7924bb096c61b8e064b65750.tar.gz vyatta-cfg-79a94470b0f3fd4f7924bb096c61b8e064b65750.zip |
initial work to parse config file into data structure.
Diffstat (limited to 'src/cnode/cnode.hpp')
-rw-r--r-- | src/cnode/cnode.hpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/cnode/cnode.hpp b/src/cnode/cnode.hpp index 0be02ca..aab2d4d 100644 --- a/src/cnode/cnode.hpp +++ b/src/cnode/cnode.hpp @@ -25,6 +25,8 @@ namespace cnode { class CfgNode { public: + CfgNode(vector<string>& path_comps, char *name, char *val, char *comment, + int deact, Cstore *cstore); CfgNode(Cstore& cstore, std::vector<string>& path_comps, bool active = false, bool recursive = true); ~CfgNode() {}; @@ -45,6 +47,9 @@ public: const std::string& getComment() const { return _comment; } const std::vector<CfgNode *>& getChildNodes() const { return _child_nodes; } + void addMultiValue(char *val) { _values.push_back(val); } + void addChildNode(CfgNode *cnode) { _child_nodes.push_back(cnode); } + private: bool _is_tag; bool _is_leaf; |