summaryrefslogtreecommitdiff
path: root/louloulibs/xmpp/xmpp_stanza.hpp
diff options
context:
space:
mode:
authorFlorent Le Coz <louiz@louiz.org>2015-09-01 04:42:12 +0200
committerFlorent Le Coz <louiz@louiz.org>2015-09-01 04:42:12 +0200
commite8f22efe34415db0e1e5cb94635b089b18efe055 (patch)
tree64088065cd97cb941b9d35016c0dcf3aaf355c5e /louloulibs/xmpp/xmpp_stanza.hpp
parentdf006a191603c4a9f0bb364affa3731c2944fef5 (diff)
downloadbiboumi-e8f22efe34415db0e1e5cb94635b089b18efe055.tar.gz
biboumi-e8f22efe34415db0e1e5cb94635b089b18efe055.tar.bz2
biboumi-e8f22efe34415db0e1e5cb94635b089b18efe055.tar.xz
biboumi-e8f22efe34415db0e1e5cb94635b089b18efe055.zip
XmlNodes are now always closed
Remove the close() method and closed attribute. Remove all the calls to close(). (Save one bool per XmlNode, yay, and save a few ifs and some useless function calls. At best it should be unnoticeably faster and lighter and save a few keystrokes in the future)
Diffstat (limited to 'louloulibs/xmpp/xmpp_stanza.hpp')
-rw-r--r--louloulibs/xmpp/xmpp_stanza.hpp7
1 files changed, 0 insertions, 7 deletions
diff --git a/louloulibs/xmpp/xmpp_stanza.hpp b/louloulibs/xmpp/xmpp_stanza.hpp
index f1a6a0f..3d5b0c5 100644
--- a/louloulibs/xmpp/xmpp_stanza.hpp
+++ b/louloulibs/xmpp/xmpp_stanza.hpp
@@ -27,7 +27,6 @@ public:
XmlNode(XmlNode&& node):
name(std::move(node.name)),
parent(node.parent),
- closed(node.closed),
attributes(std::move(node.attributes)),
children(std::move(node.children)),
inner(std::move(node.inner)),
@@ -42,7 +41,6 @@ public:
XmlNode(const XmlNode& node):
name(node.name),
parent(nullptr),
- closed(node.closed),
attributes(node.attributes),
children{},
inner(node.inner),
@@ -106,10 +104,6 @@ public:
* by calling has_children() for example.
*/
XmlNode* get_last_child() const;
- /**
- * Mark this node as closed, nothing else
- */
- void close();
XmlNode* get_parent() const;
void set_name(const std::string& name);
const std::string get_name() const;
@@ -140,7 +134,6 @@ public:
private:
std::string name;
XmlNode* parent;
- bool closed;
std::unordered_map<std::string, std::string> attributes;
std::vector<XmlNode*> children;
std::string inner;