RLib  5.7
RLib - an opensource, lightweight and multi-platform framework for cpp programming
System::Xml::XmlAttribute Class Reference

An attribute is a name-value pair. Elements have an arbitrary number of attributes, each with a unique name. More...

Inheritance diagram for System::Xml::XmlAttribute:
System::Xml::XmlBase

Public Member Functions

 XmlAttribute ()
 Construct an empty attribute.
 
 XmlAttribute (const TCHAR *_name, const TCHAR *_value)
 Construct an attribute with a name and value.
 
const StringName () const
 
const StringValue () const
 Return the name of this attribute.
 
int IntValue () const
 Return the value of this attribute.
 
double DoubleValue () const
 Return the value of this attribute, converted to an integer.
 
int QueryIntValue (int *_value) const
 Return the value of this attribute, converted to a double.
 
int QueryDoubleValue (double *_value) const
 QueryDoubleValue examines the value string. See QueryIntValue().
 
void SetName (const String &_name)
 
void SetValue (const String &_value)
 Set the name of this attribute.
 
void SetIntValue (int _value)
 Set the value.
 
void SetDoubleValue (double _value)
 Set the value from an integer.
 
const XmlAttributeNext () const
 Set the value from a double. More...
 
XmlAttributeNext ()
 
const XmlAttributePrevious () const
 Get the previous sibling attribute in the DOM. Returns null at beginning.
 
XmlAttributePrevious ()
 
bool operator== (const XmlAttribute &rhs) const
 
bool operator< (const XmlAttribute &rhs) const
 
bool operator> (const XmlAttribute &rhs) const
 
virtual const TCHAR * Parse (const TCHAR *p, XmlParsingData *data)
 
virtual void Print (IO::Stream *cfile, int depth) const
 
void Print (IO::Stream *cfile, int depth, String *str OUT) const
 
void SetDocument (XmlDocument *doc)
 
- Public Member Functions inherited from System::Xml::XmlBase
int Row () const
 
int Column () const
 See Row()
 
void SetUserData (void *user)
 Set a pointer to arbitrary user data.
 
void * GetUserData ()
 Get a pointer to arbitrary user data.
 
const void * GetUserData () const
 Get a pointer to arbitrary user data.
 

Public Attributes

 RLIB_DECLARE_DYNCREATE
 

Friends

class RLIB_API XmlAttributeSet
 

Additional Inherited Members

- Public Types inherited from System::Xml::XmlBase
enum  {
  RLIBXML_NO_ERROR = 0, RLIBXML_ERROR, RLIBXML_ERROR_OPENING_FILE, RLIBXML_ERROR_READING_STREAM,
  RLIBXML_ERROR_PARSING_ELEMENT, RLIBXML_ERROR_FAILED_TO_READ_ELEMENT_NAME, RLIBXML_ERROR_READING_ELEMENT_VALUE, RLIBXML_ERROR_READING_ATTRIBUTES,
  RLIBXML_ERROR_PARSING_EMPTY, RLIBXML_ERROR_READING_END_TAG, RLIBXML_ERROR_PARSING_UNKNOWN, RLIBXML_ERROR_PARSING_COMMENT,
  RLIBXML_ERROR_PARSING_DECLARATION, RLIBXML_ERROR_DOCUMENT_EMPTY, RLIBXML_ERROR_EMBEDDED_NULL, RLIBXML_ERROR_PARSING_CDATA,
  RLIBXML_ERROR_DOCUMENT_TOP_ONLY, RLIBXML_ERROR_MEMORY_NOT_ENOUGH, RLIBXML_ERROR_STRING_COUNT
}
 
- Static Public Member Functions inherited from System::Xml::XmlBase
static void SetCondenseWhiteSpace (bool condense)
 
static bool IsWhiteSpaceCondensed ()
 Return the current white space setting.
 
static void EncodeString (const String &str, String *out)
 
- Static Protected Member Functions inherited from System::Xml::XmlBase
static const TCHAR * SkipWhiteSpace (const TCHAR *)
 
static RLIB_INLINE bool IsWhiteSpace (TCHAR c)
 
static RLIB_INLINE bool IsWhiteSpace (int c)
 
static const TCHAR * ReadName (const TCHAR *p, String *name)
 
static const TCHAR * ReadText (const TCHAR *in, String *text, bool ignoreWhiteSpace, const TCHAR *endTag, bool ignoreCase)
 
static const TCHAR * GetEntity (const TCHAR *in, TCHAR *value, int *length)
 
static RLIB_INLINE const TCHAR * GetChar (const TCHAR *p, TCHAR *_value, int *length)
 
static bool StringEqual (const TCHAR *p, const TCHAR *endTag, bool ignoreCase)
 
static int IsAlpha (TCHAR anyByte)
 
static int IsAlphaNum (TCHAR anyByte)
 
static RLIB_INLINE int ToLower (int v)
 
- Protected Attributes inherited from System::Xml::XmlBase
XmlCursor location
 
void * userData
 Field containing a generic user pointer.
 

Detailed Description

An attribute is a name-value pair. Elements have an arbitrary number of attributes, each with a unique name.

Note
The attributes are not XmlNodes, since they are not part of the tinyXML document object model. There are other suggested ways to look at this problem.

Member Function Documentation

const XmlAttribute * XmlAttribute::Next ( ) const

Set the value from a double.

Get the next sibling attribute in the DOM. Returns null at end.


The documentation for this class was generated from the following files: