80 const std::string&
getName()
const {
return nameOrText_; }
88 const std::string&
getText()
const {
return nameOrText_; }
96 void addChild(HXMLNode&& child);
116 const std::vector<HXMLNode>&
getChildren()
const {
return children_; }
122 void addAttribute(
const std::string& name,
const GenericValue& value);
127 const std::map<std::string, GenericValue>&
getAttributes()
const {
return attributes_; }
133 ValueView getAttribute(
const std::string& name);
138 void clearChildren();
142 void clearAttributes();
154 bool generateXML(FILE* file,
int indent)
const;
159 std::string escapeXML(
const std::string& str)
const;
163 std::string nameOrText_{};
164 std::vector<HXMLNode> children_;
165 std::map<std::string, GenericValue> attributes_;