summaryrefslogtreecommitdiff
path: root/src/pugixml.cpp
diff options
context:
space:
mode:
authorarseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640>2010-10-26 17:09:34 +0000
committerarseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640>2010-10-26 17:09:34 +0000
commit09b5dfdcb0707c39874997efbf207ff554334c34 (patch)
tree6f1ec740a22d766a419574e95122aa7322342179 /src/pugixml.cpp
parent948cb037aec073255d71a19ae1f9f5a351deff72 (diff)
Added xml_document::reset, added append/prepend/insert child overloads for elements (with explicit name)
git-svn-id: http://pugixml.googlecode.com/svn/trunk@779 99668b35-9821-0410-8761-19e4c4f06640
Diffstat (limited to 'src/pugixml.cpp')
-rw-r--r--src/pugixml.cpp36
1 files changed, 36 insertions, 0 deletions
diff --git a/src/pugixml.cpp b/src/pugixml.cpp
index 833e43e..6850589 100644
--- a/src/pugixml.cpp
+++ b/src/pugixml.cpp
@@ -3989,6 +3989,42 @@ namespace pugi
return n;
}
+ xml_node xml_node::append_child(const char_t* name)
+ {
+ xml_node result = append_child(node_element);
+
+ result.set_name(name);
+
+ return result;
+ }
+
+ xml_node xml_node::prepend_child(const char_t* name)
+ {
+ xml_node result = prepend_child(node_element);
+
+ result.set_name(name);
+
+ return result;
+ }
+
+ xml_node xml_node::insert_child_after(const char_t* name, const xml_node& node)
+ {
+ xml_node result = insert_child_after(node_element, node);
+
+ result.set_name(name);
+
+ return result;
+ }
+
+ xml_node xml_node::insert_child_before(const char_t* name, const xml_node& node)
+ {
+ xml_node result = insert_child_before(node_element, node);
+
+ result.set_name(name);
+
+ return result;
+ }
+
xml_node xml_node::append_copy(const xml_node& proto)
{
xml_node result = append_child(proto.type());