diff options
author | crupest <crupest@outlook.com> | 2021-12-31 00:26:55 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2021-12-31 00:26:55 +0800 |
commit | 4e92e8709b30c385e1a88d7d4f76c50ee4a3d736 (patch) | |
tree | 2720fa8b17a9108617e54063b4fd06db7b28dbcb /src/xml/XmlNode.cpp | |
parent | aa923364615b77e152d532b021fe1536fcf96a50 (diff) | |
download | cru-4e92e8709b30c385e1a88d7d4f76c50ee4a3d736.tar.gz cru-4e92e8709b30c385e1a88d7d4f76c50ee4a3d736.tar.bz2 cru-4e92e8709b30c385e1a88d7d4f76c50ee4a3d736.zip |
...
Diffstat (limited to 'src/xml/XmlNode.cpp')
-rw-r--r-- | src/xml/XmlNode.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/xml/XmlNode.cpp b/src/xml/XmlNode.cpp new file mode 100644 index 00000000..cfeb5cf9 --- /dev/null +++ b/src/xml/XmlNode.cpp @@ -0,0 +1,14 @@ +#include "cru/xml/XmlNode.hpp" + +namespace cru::xml { +bool operator==(const XmlNode& lhs, const XmlNode& rhs) { + return lhs.GetType() == rhs.GetType() && lhs.GetText() == rhs.GetText() && + lhs.GetTag() == rhs.GetTag() && + lhs.GetAttributes() == rhs.GetAttributes() && + lhs.GetChildren() == rhs.GetChildren(); +} + +bool operator!=(const XmlNode& lhs, const XmlNode& rhs) { + return !(lhs == rhs); +} +} // namespace cru::xml |