summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/pugixml.cpp8
-rw-r--r--src/pugixml.hpp8
2 files changed, 8 insertions, 8 deletions
diff --git a/src/pugixml.cpp b/src/pugixml.cpp
index 3a01c27..ad39ba7 100644
--- a/src/pugixml.cpp
+++ b/src/pugixml.cpp
@@ -2664,7 +2664,7 @@ namespace pugi
}
}
- void xml_node::print(xml_writer& writer, const char* indent, unsigned int flags, unsigned int depth)
+ void xml_node::print(xml_writer& writer, const char* indent, unsigned int flags, unsigned int depth) const
{
if (!_root) return;
@@ -2674,7 +2674,7 @@ namespace pugi
}
#ifndef PUGIXML_NO_STL
- void xml_node::print(std::ostream& stream, const char* indent, unsigned int flags, unsigned int depth)
+ void xml_node::print(std::ostream& stream, const char* indent, unsigned int flags, unsigned int depth) const
{
if (!_root) return;
@@ -3035,7 +3035,7 @@ namespace pugi
return res;
}
- void xml_document::save(xml_writer& writer, const char* indent, unsigned int flags)
+ void xml_document::save(xml_writer& writer, const char* indent, unsigned int flags) const
{
xml_buffered_writer buffered_writer(writer);
@@ -3054,7 +3054,7 @@ namespace pugi
node_output(buffered_writer, *this, indent, flags, 0);
}
- bool xml_document::save_file(const char* name, const char* indent, unsigned int flags)
+ bool xml_document::save_file(const char* name, const char* indent, unsigned int flags) const
{
FILE* file = fopen(name, "wb");
if (!file) return false;
diff --git a/src/pugixml.hpp b/src/pugixml.hpp
index 79f3986..062fcdb 100644
--- a/src/pugixml.hpp
+++ b/src/pugixml.hpp
@@ -1258,7 +1258,7 @@ namespace pugi
* \param flags - formatting flags
* \param depth - starting depth (used for indentation)
*/
- void print(xml_writer& writer, const char* indent = "\t", unsigned int flags = format_default, unsigned int depth = 0);
+ void print(xml_writer& writer, const char* indent = "\t", unsigned int flags = format_default, unsigned int depth = 0) const;
#ifndef PUGIXML_NO_STL
/**
@@ -1270,7 +1270,7 @@ namespace pugi
* \param depth - starting depth (used for indentation)
* \deprecated Use print() with xml_writer_stream instead
*/
- void print(std::ostream& os, const char* indent = "\t", unsigned int flags = format_default, unsigned int depth = 0);
+ void print(std::ostream& os, const char* indent = "\t", unsigned int flags = format_default, unsigned int depth = 0) const;
#endif
/**
@@ -1708,7 +1708,7 @@ namespace pugi
* \param indent - indentation string
* \param flags - formatting flags
*/
- void save(xml_writer& writer, const char* indent = "\t", unsigned int flags = format_default);
+ void save(xml_writer& writer, const char* indent = "\t", unsigned int flags = format_default) const;
/**
* Save XML to file
@@ -1718,7 +1718,7 @@ namespace pugi
* \param flags - formatting flags
* \return success flag
*/
- bool save_file(const char* name, const char* indent = "\t", unsigned int flags = format_default);
+ bool save_file(const char* name, const char* indent = "\t", unsigned int flags = format_default) const;
/**
* Compute document order for the whole tree