25 #ifndef TINYXML2_INCLUDED 26 #define TINYXML2_INCLUDED 28 #if defined(ANDROID_NDK) || defined(__BORLANDC__) 55 #if defined( _DEBUG ) || defined( DEBUG ) || defined (__DEBUG__) 62 # pragma warning(push) 63 # pragma warning(disable: 4251) 67 # ifdef TINYXML2_EXPORT 68 # define TINYXML2_LIB __declspec(dllexport) 69 # elif defined(TINYXML2_IMPORT) 70 # define TINYXML2_LIB __declspec(dllimport) 80 # if defined(_MSC_VER) 81 # define TIXMLASSERT( x ) if ( !(x)) { __debugbreak(); } //if ( !(x)) WinDebugBreak() 82 # elif defined (ANDROID_NDK) 83 # include <android/log.h> 84 # define TIXMLASSERT( x ) if ( !(x)) { __android_log_assert( "assert", "grinliz", "ASSERT in '%s' at %d.", __FILE__, __LINE__ ); } 87 # define TIXMLASSERT assert 90 # define TIXMLASSERT( x ) {} 94 #if defined(_MSC_VER) && (_MSC_VER >= 1400 ) 103 inline int TIXML_SNPRINTF(
char* buffer,
size_t size,
const char* format, ... )
106 va_start( va, format );
107 int result = vsnprintf_s( buffer, size, _TRUNCATE, format, va );
111 #define TIXML_SSCANF sscanf_s 115 #define TIXML_SNPRINTF snprintf 116 #define TIXML_SSCANF sscanf 130 class XMLDeclaration;
159 void Set(
char* start,
char* end,
int flags ) {
174 _start =
const_cast<char*
>(str);
177 void SetStr(
const char* str,
int flags=0 );
179 char*
ParseText(
char* in,
const char* endTag,
int strFlags );
203 template <
class T,
int INIT>
214 if ( _mem != _pool ) {
220 EnsureCapacity( _size+1 );
225 EnsureCapacity( _size+count );
226 T* ret = &_mem[_size];
232 return _mem[--_size];
256 return _mem[ _size - 1];
277 if ( cap > _allocated ) {
278 int newAllocated = cap * 2;
279 T* newMem =
new T[newAllocated];
280 memcpy( newMem, _mem,
sizeof(T)*_size );
281 if ( _mem != _pool ) {
285 _allocated = newAllocated;
306 virtual int ItemSize()
const = 0;
307 virtual void* Alloc() = 0;
308 virtual void Free(
void* ) = 0;
309 virtual void SetTracked() = 0;
320 MemPoolT() : _root(0), _currentAllocs(0), _nAllocs(0), _maxAllocs(0), _nUntracked(0) {}
323 for(
int i=0; i<_blockPtrs.Size(); ++i ) {
324 delete _blockPtrs[i];
332 return _currentAllocs;
338 Block* block =
new Block();
339 _blockPtrs.Push( block );
341 for(
int i=0; i<COUNT-1; ++i ) {
342 block->chunk[i].next = &block->chunk[i+1];
344 block->chunk[COUNT-1].next = 0;
345 _root = block->chunk;
347 void* result = _root;
351 if ( _currentAllocs > _maxAllocs ) {
352 _maxAllocs = _currentAllocs;
358 virtual void Free(
void* mem ) {
363 Chunk* chunk = (Chunk*)mem;
365 memset( chunk, 0xfe,
sizeof(Chunk) );
371 printf(
"Mempool %s watermark=%d [%dk] current=%d size=%d nAlloc=%d blocks=%d\n",
372 name, _maxAllocs, _maxAllocs*SIZE/1024, _currentAllocs, SIZE, _nAllocs, _blockPtrs.Size() );
392 enum { COUNT = (4*1024)/SIZE };
483 while( !IsUTF8Continuation(*p) && isspace( *reinterpret_cast<const unsigned char*>(p) ) ) {
489 while( !IsUTF8Continuation(*p) && isspace( *reinterpret_cast<unsigned char*>(p) ) ) {
495 return !IsUTF8Continuation(p) && isspace( static_cast<unsigned char>(p) );
499 return ( ( ch < 128 ) ? isalpha( ch ) : 1 )
505 return IsNameStartChar( ch )
511 inline static bool StringEqual(
const char* p,
const char* q,
int nChar=INT_MAX ) {
516 while( *p && *q && *p == *q && n<nChar ) {
521 if ( (n == nChar) || ( *p == 0 && *q == 0 ) ) {
531 static const char* ReadBOM(
const char* p,
bool* hasBOM );
534 static const char* GetCharacterRef(
const char* p,
char* value,
int* length );
535 static void ConvertUTF32ToUTF8(
unsigned long input,
char* output,
int* length );
538 static void ToStr(
int v,
char* buffer,
int bufferSize );
539 static void ToStr(
unsigned v,
char* buffer,
int bufferSize );
540 static void ToStr(
bool v,
char* buffer,
int bufferSize );
541 static void ToStr(
float v,
char* buffer,
int bufferSize );
542 static void ToStr(
double v,
char* buffer,
int bufferSize );
545 static bool ToLong(
const char* str,
long* value );
546 static bool ToInt(
const char* str,
int* value );
547 static bool ToUnsigned(
const char* str,
unsigned* value );
548 static bool ToBool(
const char* str,
bool* value );
549 static bool ToFloat(
const char* str,
float* value );
550 static bool ToDouble(
const char* str,
double* value );
648 return _value.GetStr();
654 void SetValue(
const char* val,
bool staticMem=
false );
682 const XMLElement* FirstChildElement(
const char* value=0 )
const;
685 return const_cast<XMLElement*
>(
const_cast<const XMLNode*
>(
this)->FirstChildElement( value ));
694 return const_cast<XMLNode*
>(
const_cast<const XMLNode*
>(
this)->LastChild() );
700 const XMLElement* LastChildElement(
const char* value=0 )
const;
703 return const_cast<XMLElement*
>(
const_cast<const XMLNode*
>(
this)->LastChildElement(value) );
716 const XMLElement* PreviousSiblingElement(
const char* value=0 )
const ;
719 return const_cast<XMLElement*
>(
const_cast<const XMLNode*
>(
this)->PreviousSiblingElement( value ) );
732 const XMLElement* NextSiblingElement(
const char* value=0 )
const;
735 return const_cast<XMLElement*
>(
const_cast<const XMLNode*
>(
this)->NextSiblingElement( value ) );
744 return InsertEndChild( addThis );
758 void DeleteChildren();
763 void DeleteChild(
XMLNode* node );
782 virtual bool ShallowEqual(
const XMLNode* compare )
const = 0;
806 virtual bool Accept(
XMLVisitor* visitor )
const = 0;
809 virtual char* ParseDeep(
char*,
StrPair* );
847 friend class XMLBase;
850 virtual bool Accept(
XMLVisitor* visitor )
const;
868 char* ParseDeep(
char*,
StrPair* endTag );
870 virtual bool ShallowEqual(
const XMLNode* compare )
const;
895 virtual bool Accept(
XMLVisitor* visitor )
const;
897 char* ParseDeep(
char*,
StrPair* endTag );
899 virtual bool ShallowEqual(
const XMLNode* compare )
const;
933 virtual bool Accept(
XMLVisitor* visitor )
const;
935 char* ParseDeep(
char*,
StrPair* endTag );
937 virtual bool ShallowEqual(
const XMLNode* compare )
const;
965 virtual bool Accept(
XMLVisitor* visitor )
const;
967 char* ParseDeep(
char*,
StrPair* endTag );
969 virtual bool ShallowEqual(
const XMLNode* compare )
const;
1019 return _name.GetStr();
1023 return _value.GetStr();
1036 QueryIntValue( &i );
1042 QueryUnsignedValue( &i );
1048 QueryBoolValue( &b );
1054 QueryDoubleValue( &d );
1060 QueryFloatValue( &f );
1068 XMLError QueryLongValue(
long* value )
const;
1070 XMLError QueryIntValue(
int* value )
const;
1072 XMLError QueryUnsignedValue(
unsigned int* value )
const;
1074 XMLError QueryBoolValue(
bool* value )
const;
1076 XMLError QueryDoubleValue(
double* value )
const;
1078 XMLError QueryFloatValue(
float* value )
const;
1081 void SetAttribute(
const char* value );
1083 void SetAttribute(
int value );
1085 void SetAttribute(
unsigned value );
1087 void SetAttribute(
bool value );
1089 void SetAttribute(
double value );
1091 void SetAttribute(
float value );
1094 enum { BUF_SIZE = 200 };
1101 void SetName(
const char* name );
1103 char* ParseDeep(
char* p,
bool processEntities );
1118 friend class XMLBase;
1126 void SetName(
const char* str,
bool staticMem=
false ) {
1127 SetValue( str, staticMem );
1136 virtual bool Accept(
XMLVisitor* visitor )
const;
1161 const char* Attribute(
const char* name,
const char* value=0 )
const;
1170 QueryIntAttribute( name, &i );
1176 QueryUnsignedAttribute( name, &i );
1182 QueryBoolAttribute( name, &b );
1188 QueryDoubleAttribute( name, &d );
1194 QueryFloatAttribute( name, &f );
1279 return QueryIntAttribute( name, value );
1283 return QueryUnsignedAttribute( name, value );
1287 return QueryBoolAttribute( name, value );
1291 return QueryDoubleAttribute( name, value );
1295 return QueryFloatAttribute( name, value );
1327 void DeleteAttribute(
const char* name );
1331 return _rootAttribute;
1334 const XMLAttribute* FindAttribute(
const char* name )
const;
1364 const char* GetText()
const;
1392 XMLError QueryIntText(
int* ival )
const;
1394 XMLError QueryUnsignedText(
unsigned* uval )
const;
1396 XMLError QueryBoolText(
bool* bval )
const;
1398 XMLError QueryDoubleText(
double* dval )
const;
1400 XMLError QueryFloatText(
float* fval )
const;
1409 return _closingType;
1411 char* ParseDeep(
char* p,
StrPair* endTag );
1413 virtual bool ShallowEqual(
const XMLNode* compare )
const;
1422 XMLAttribute* FindOrCreateAttribute(
const char* name );
1424 char* ParseAttributes(
char* p );
1470 XMLError Parse(
const char* xml,
size_t nBytes=(
size_t)(-1) );
1477 XMLError LoadFile(
const char* filename );
1493 XMLError SaveFile(
const char* filename,
bool compact =
false );
1502 XMLError SaveFile( FILE* fp,
bool compact =
false );
1505 return _processEntities;
1527 return FirstChildElement();
1530 return FirstChildElement();
1548 virtual bool Accept(
XMLVisitor* visitor )
const;
1561 XMLComment* NewComment(
const char* comment );
1567 XMLText* NewText(
const char* text );
1595 void SetError(
XMLError error,
const char* str1,
const char* str2 );
1614 void PrintError()
const;
1620 char* Identify(
char* p,
XMLNode** node );
1726 return XMLHandle( _node ? _node->FirstChild() : 0 );
1730 return XMLHandle( _node ? _node->FirstChildElement( value ) : 0 );
1734 return XMLHandle( _node ? _node->LastChild() : 0 );
1738 return XMLHandle( _node ? _node->LastChildElement( _value ) : 0 );
1742 return XMLHandle( _node ? _node->PreviousSibling() : 0 );
1746 return XMLHandle( _node ? _node->PreviousSiblingElement( _value ) : 0 );
1750 return XMLHandle( _node ? _node->NextSibling() : 0 );
1754 return XMLHandle( _node ? _node->NextSiblingElement( _value ) : 0 );
1763 return ( ( _node && _node->ToElement() ) ? _node->ToElement() : 0 );
1767 return ( ( _node && _node->ToText() ) ? _node->ToText() : 0 );
1771 return ( ( _node && _node->ToUnknown() ) ? _node->ToUnknown() : 0 );
1775 return ( ( _node && _node->ToDeclaration() ) ? _node->ToDeclaration() : 0 );
1809 return XMLConstHandle( _node ? _node->FirstChildElement( value ) : 0 );
1815 return XMLConstHandle( _node ? _node->LastChildElement( _value ) : 0 );
1821 return XMLConstHandle( _node ? _node->PreviousSiblingElement( _value ) : 0 );
1827 return XMLConstHandle( _node ? _node->NextSiblingElement( _value ) : 0 );
1835 return ( ( _node && _node->ToElement() ) ? _node->ToElement() : 0 );
1838 return ( ( _node && _node->ToText() ) ? _node->ToText() : 0 );
1841 return ( ( _node && _node->ToUnknown() ) ? _node->ToUnknown() : 0 );
1844 return ( ( _node && _node->ToDeclaration() ) ? _node->ToDeclaration() : 0 );
1903 XMLPrinter( FILE* file=0,
bool compact =
false,
int depth = 0 );
1907 void PushHeader(
bool writeBOM,
bool writeDeclaration );
1911 void OpenElement(
const char* name );
1913 void PushAttribute(
const char* name,
const char* value );
1914 void PushAttribute(
const char* name,
int value );
1915 void PushAttribute(
const char* name,
unsigned value );
1916 void PushAttribute(
const char* name,
bool value );
1917 void PushAttribute(
const char* name,
double value );
1919 virtual void CloseElement();
1922 void PushText(
const char* text,
bool cdata=
false ,
bool specrow=
false );
1924 void PushText(
int value );
1926 void PushText(
unsigned value );
1928 void PushText(
bool value );
1930 void PushText(
float value );
1932 void PushText(
double value );
1935 void PushComment(
const char* comment );
1937 void PushDeclaration(
const char* value );
1938 void PushUnknown(
const char* value );
1946 virtual bool VisitExit(
const XMLElement& element );
1948 virtual bool Visit(
const XMLText& text );
1949 virtual bool Visit(
const XMLComment& comment );
1951 virtual bool Visit(
const XMLUnknown& unknown );
1958 return _buffer.Mem();
1966 return _buffer.Size();
1975 void PrintSpace(
int depth );
1976 void PrintString(
const char*,
bool restrictedEntitySet );
1977 void Print(
const char* format, ... );
1990 bool _entityFlag[ENTITY_RANGE];
1991 bool _restrictedEntityFlag[ENTITY_RANGE];
2002 #if defined(_MSC_VER) 2003 # pragma warning(pop) 2006 #endif // TINYXML2_INCLUDED virtual XMLElement * ToElement()
Safely cast to an Element, or null.
double DoubleAttribute(const char *name) const
See IntAttribute()
int QueryAttribute(const char *name, int *value) const
Given an attribute name, QueryAttribute() returns XML_NO_ERROR, XML_WRONG_ATTRIBUTE_TYPE if the conve...
int QueryAttribute(const char *name, bool *value) const
const XMLDeclaration * ToDeclaration() const
void CollapseWhitespace()
bool BoolValue() const
Query as a boolean. See IntValue()
bool Error() const
Return true if there was an error parsing the document.
const XMLConstHandle FirstChild() const
const XMLConstHandle LastChild() const
XMLError QueryIntValue(int *value) const
See QueryIntValue.
const XMLText * ToText() const
virtual void Free(void *mem)
static const int TIXML2_PATCH_VERSION
XMLError QueryUnsignedAttribute(const char *name, unsigned int *value) const
See QueryIntAttribute()
virtual const XMLDeclaration * ToDeclaration() const
virtual XMLDocument * ToDocument()
Safely cast to a Document, or null.
XMLHandle(XMLNode *node)
Create a handle from any node (at any depth of the tree.) This can be a null pointer.
virtual const XMLComment * ToComment() const
XMLError QueryFloatValue(float *value) const
See QueryIntValue.
XMLAttribute * _rootAttribute
MemPoolT< sizeof(XMLAttribute) > _attributePool
static const char * SkipWhiteSpace(const char *p)
const T & operator[](int i) const
int CurrentAllocs() const
void SetAttribute(const char *name, unsigned value)
Sets the named attribute to value.
virtual XMLComment * ToComment()
Safely cast to a Comment, or null.
XMLConstHandle & operator=(const XMLConstHandle &ref)
virtual const XMLText * ToText() const
virtual bool VisitEnter(const XMLElement &, const XMLAttribute *)
Visit an element.
bool CData() const
Returns true if this is a CDATA text element.
void Set(char *start, char *end, int flags)
DynArray< Block *, 10 > _blockPtrs
A variant of the XMLHandle class for working with const XMLNodes and Documents.
static bool IsNameChar(unsigned char ch)
static bool IsWhiteSpace(char p)
XMLHandle LastChildElement(const char *_value=0)
Get the last child element of this handle.
const XMLElement * RootElement() const
virtual XMLUnknown * ToUnknown()
Safely cast to an Unknown, or null.
virtual bool Visit(const XMLText &)
Visit a text node.
const XMLNode * FirstChild() const
Get the first child node, or null if none exists.
const char * Name() const
The name of the attribute.
virtual bool ShallowEqual(const XMLNode *) const
Test if 2 nodes are the same, but don't test children.
The element is a container class.
static char * SkipWhiteSpace(char *p)
double DoubleValue() const
Query as a double. See IntValue()
XMLConstHandle(const XMLNode *node)
XMLNode * PreviousSibling()
virtual bool VisitExit(const XMLDocument &)
Visit a document.
char * ParseName(char *in)
XMLConstHandle(const XMLNode &node)
int QueryAttribute(const char *name, double *value) const
void SetAttribute(const char *value)
Set the attribute to a string value.
virtual const XMLText * ToText() const
XMLError QueryFloatAttribute(const char *name, float *value) const
See QueryIntAttribute()
virtual const XMLUnknown * ToUnknown() const
const XMLNode * ToNode() const
const XMLConstHandle PreviousSibling() const
virtual XMLText * ToText()
Safely cast to Text, or null.
virtual bool Visit(const XMLComment &)
Visit a comment node.
int IntAttribute(const char *name) const
Given an attribute name, IntAttribute() returns the value of the attribute interpreted as an integer...
XMLHandle LastChild()
Get the last child of this handle.
const char * Value() const
The value of the attribute.
virtual XMLNode * ShallowClone(XMLDocument *) const
Make a copy of this node, but not its children.
const T & PeekTop() const
void SetAttribute(const char *name, const char *value)
Sets the named attribute to value.
A Document binds together all the functionality.
const char * GetErrorStr2() const
Return a possibly helpful secondary diagnostic location or string.
static const int TIXML2_MINOR_VERSION
const XMLUnknown * ToUnknown() const
XMLHandle & operator=(const XMLHandle &ref)
Assignment.
const XMLConstHandle NextSibling() const
void SetBOM(bool useBOM)
Sets whether to write the BOM when writing the file.
XMLError QueryDoubleValue(double *value) const
See QueryIntValue.
bool ProcessEntities() const
DynArray< char, 20 > _buffer
const XMLConstHandle NextSiblingElement(const char *_value=0) const
XMLError ErrorID() const
Return the errorID.
XMLElement * RootElement()
Return the root element of DOM.
Any tag that TinyXML-2 doesn't recognize is saved as an unknown.
A XMLHandle is a class that wraps a node pointer with null checks; this is an incredibly useful thing...
const XMLNode * Parent() const
Get the parent of this node on the DOM.
const XMLAttribute * Next() const
The next attribute in the list.
XMLError QueryDoubleAttribute(const char *name, double *value) const
See QueryIntAttribute()
void SetName(const char *str, bool staticMem=false)
Set the name of the element.
virtual int ItemSize() const
XMLNode is a base class for every object that is in the XML Document Object Model (DOM)...
void SetAttribute(const char *name, double value)
Sets the named attribute to value.
int IntValue() const
IntValue interprets the attribute as an integer, and returns the value.
int QueryAttribute(const char *name, float *value) const
static const int TIXML2_MAJOR_VERSION
const char * Value() const
The meaning of 'value' changes for the specific type.
void DeleteNode(XMLNode *node)
Delete a node associated with this document.
MemPoolT< sizeof(XMLComment) > _commentPool
XMLHandle NextSiblingElement(const char *_value=0)
Get the next sibling element of this handle.
An attribute is a name-value pair.
bool BoolAttribute(const char *name) const
See IntAttribute()
const XMLConstHandle LastChildElement(const char *_value=0) const
virtual bool VisitExit(const XMLDocument &)
Visit a document.
void SetStr(const char *str, int flags=0)
XMLHandle(XMLNode &node)
Create a handle from a node.
void SetCData(bool isCData)
Declare whether this should be CDATA or standard text.
XMLDocument * GetDocument()
Get the XMLDocument that owns this XMLNode.
XMLError QueryLongAttribute(const char *name, long *value) const
Given an attribute name, QueryIntAttribute() returns XML_NO_ERROR, XML_WRONG_ATTRIBUTE_TYPE if the co...
const XMLDocument * GetDocument() const
Get the XMLDocument that owns this XMLNode.
virtual XMLDeclaration * ToDeclaration()
Safely cast to a Declaration, or null.
virtual XMLUnknown * ToUnknown()
Safely cast to an Unknown, or null.
static bool StringEqual(const char *p, const char *q, int nChar=INT_MAX)
unsigned UnsignedAttribute(const char *name) const
See IntAttribute()
virtual bool VisitExit(const XMLElement &)
Visit an element.
virtual const XMLElement * ToElement() const
virtual bool Visit(const XMLUnknown &)
Visit an unknown node.
XMLConstHandle(const XMLConstHandle &ref)
const XMLNode * PreviousSibling() const
Get the previous (left) sibling node of this node.
const XMLConstHandle FirstChildElement(const char *value=0) const
virtual const XMLDeclaration * ToDeclaration() const
XMLNode * LinkEndChild(XMLNode *addThis)
In correct XML the declaration is the first entry in the file.
void SetAttribute(const char *name, bool value)
Sets the named attribute to value.
const char * GetErrorStr1() const
Return a possibly helpful diagnostic location or string.
DynArray< const char *, 10 > _stack
XMLError QueryIntAttribute(const char *name, int *value) const
XMLNode * ToNode()
Safe cast to XMLNode. This can return null.
void Trace(const char *name)
Implements the interface to the "Visitor pattern" (see the Accept() method.) If you call the Accept()...
XMLHandle NextSibling()
Get the next sibling of this handle.
unsigned UnsignedValue() const
Query as an unsigned integer. See IntValue()
XMLError QueryUnsignedValue(unsigned int *value) const
See QueryIntValue.
XMLText(XMLDocument *doc)
static bool IsNameStartChar(unsigned char ch)
const XMLElement * ToElement() const
void DeleteChild(XMLNode *node)
Delete a child of this node.
virtual XMLText * ToText()
Safely cast to Text, or null.
void SetAttribute(const char *name, int value)
Sets the named attribute to value.
XMLError QueryBoolAttribute(const char *name, bool *value) const
See QueryIntAttribute()
bool HasBOM() const
Returns true if this document has a leading Byte Order Mark of UTF8.
void EnsureCapacity(int cap)
XMLText * ToText()
Safe cast to XMLText. This can return null.
int QueryAttribute(const char *name, unsigned int *value) const
const XMLNode * LastChild() const
Get the last child node, or null if none exists.
static int IsUTF8Continuation(const char p)
XMLHandle PreviousSibling()
Get the previous sibling of this handle.
MemPoolT< sizeof(XMLText) > _textPool
XMLDeclaration * ToDeclaration()
Safe cast to XMLDeclaration. This can return null.
bool NoChildren() const
Returns true if this node has no children.
virtual const XMLDocument * ToDocument() const
int CStrSize() const
If in print to memory mode, return the size of the XML file in memory.
MemPoolT< sizeof(XMLElement) > _elementPool
const XMLAttribute * FirstAttribute() const
Return the first attribute in the list.
XMLUnknown * ToUnknown()
Safe cast to XMLUnknown. This can return null.
const XMLConstHandle PreviousSiblingElement(const char *_value=0) const
XMLHandle FirstChild()
Get the first child of this handle.
XMLElement * FirstChildElement(const char *value=0)
virtual const XMLUnknown * ToUnknown() const
XMLElement * ToElement()
Safe cast to XMLElement. This can return null.
float FloatAttribute(const char *name) const
See IntAttribute()
virtual bool Visit(const XMLDeclaration &)
Visit a declaration.
virtual bool VisitEnter(const XMLDocument &)
Visit a document.
XMLElement * NextSiblingElement(const char *value=0)
XMLElement * LastChildElement(const char *value=0)
virtual const XMLElement * ToElement() const
char * ParseText(char *in, const char *endTag, int strFlags)
XMLError QueryBoolValue(bool *value) const
See QueryIntValue.
virtual XMLDocument * ToDocument()
Safely cast to a Document, or null.
Whitespace WhitespaceMode() const
float FloatValue() const
Query as a float. See IntValue()
virtual XMLDeclaration * ToDeclaration()
Safely cast to a Declaration, or null.
XMLHandle PreviousSiblingElement(const char *_value=0)
Get the previous sibling element of this handle.
virtual XMLElement * ToElement()
Safely cast to an Element, or null.
const XMLNode * NextSibling() const
Get the next (right) sibling node of this node.
XMLError QueryLongValue(long *value) const
QueryIntValue interprets the attribute as an integer, and returns the value in the provided parameter...
XMLHandle(const XMLHandle &ref)
Copy constructor.
virtual const XMLDocument * ToDocument() const
XMLElement * PreviousSiblingElement(const char *value=0)
const char * CStr() const
If in print to memory mode, return a pointer to the XML file in memory.
const char * Name() const
Get the name of an element (which is the Value() of the node.)
XMLHandle FirstChildElement(const char *value=0)
Get the first child element of this handle.
void SetInternedStr(const char *str)