summaryrefslogtreecommitdiff
path: root/src/pugixml.cpp
diff options
context:
space:
mode:
authorarseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640>2010-09-21 19:30:03 +0000
committerarseny.kapoulkine <arseny.kapoulkine@99668b35-9821-0410-8761-19e4c4f06640>2010-09-21 19:30:03 +0000
commit70d88da72709b7de129b893ad4edcc82cf5872ab (patch)
tree7d56f9b39f08b6295447cc7fd82717bb274691d1 /src/pugixml.cpp
parent41d1d91bc56efec947c12f253de730bb8ace685f (diff)
Major header cleanup: removed redundant comments (single-line function/type descriptions are left for convenience), removed parse()/as_utf16(), removed deprecated function tests
git-svn-id: http://pugixml.googlecode.com/svn/trunk@746 99668b35-9821-0410-8761-19e4c4f06640
Diffstat (limited to 'src/pugixml.cpp')
-rw-r--r--src/pugixml.cpp36
1 files changed, 21 insertions, 15 deletions
diff --git a/src/pugixml.cpp b/src/pugixml.cpp
index 1790185..8b2f35c 100644
--- a/src/pugixml.cpp
+++ b/src/pugixml.cpp
@@ -4253,6 +4253,15 @@ namespace pugi
return temp;
}
+ xml_parse_result::xml_parse_result(): status(status_internal_error), offset(0), encoding(encoding_auto)
+ {
+ }
+
+ xml_parse_result::operator bool() const
+ {
+ return status == status_ok;
+ }
+
const char* xml_parse_result::description() const
{
switch (status)
@@ -4379,16 +4388,6 @@ namespace pugi
return load_buffer(contents, strlength(contents) * sizeof(char_t), options, encoding);
}
- xml_parse_result xml_document::parse(char* xmlstr, unsigned int options)
- {
- return load_buffer_inplace(xmlstr, strlen(xmlstr), options, encoding_utf8);
- }
-
- xml_parse_result xml_document::parse(const transfer_ownership_tag&, char* xmlstr, unsigned int options)
- {
- return load_buffer_inplace_own(xmlstr, strlen(xmlstr), options, encoding_utf8);
- }
-
xml_parse_result xml_document::load_file(const char* path, unsigned int options, xml_encoding encoding)
{
reset();
@@ -4543,11 +4542,6 @@ namespace pugi
return result;
}
- std::wstring PUGIXML_FUNCTION as_utf16(const char* str)
- {
- return as_wide(str);
- }
-
std::wstring PUGIXML_FUNCTION as_wide(const char* str)
{
assert(str);
@@ -8956,11 +8950,23 @@ namespace pugi
}
};
+ xpath_parse_result::xpath_parse_result(): error("Internal error"), offset(0)
+ {
+ }
+
+ xpath_parse_result::operator bool() const
+ {
+ return error == 0;
+ }
const char* xpath_parse_result::description() const
{
return error ? error : "No error";
}
+ xpath_variable::xpath_variable()
+ {
+ }
+
const char_t* xpath_variable::name() const
{
switch (_type)