sptk2 logo
SPTK Home Page

sptk::CXmlAttribute Class Reference
[XML]

XML attribute is just a named item. More...

#include <CXmlAttributes.h>

Inheritance diagram for sptk::CXmlAttribute:

sptk::CXmlNamedItem sptk::CXmlNode

List of all members.

Public Member Functions

virtual const std::string & value () const
 Returns the value of the node.
virtual void value (const std::string &new_value)
 Sets new value to node.
virtual void value (const char *new_value)
 Sets new value to node.

Protected Member Functions

 CXmlAttribute (CXmlElement *parent, const std::string &name, CXmlValue value)
 Protected constructor (internal).
 CXmlAttribute (CXmlElement *parent, const char *name, CXmlValue value)
 Protected constructor (internal).

Protected Attributes

std::string m_value
 Attribute value.

Friends

class CXmlAttributes


Detailed Description

XML attribute is just a named item.

Constructor & Destructor Documentation

sptk::CXmlAttribute::CXmlAttribute ( CXmlElement parent,
const std::string &  name,
CXmlValue  value 
) [protected]

Protected constructor (internal).

Creates a new attribute. Doesn't verify if the attribute name already exists in parent element

Parameters:
parent CXmlElement*, parent element (can't be NULL)
name const std::string&, attribute name
value CXmlValue, attribute value

sptk::CXmlAttribute::CXmlAttribute ( CXmlElement parent,
const char *  name,
CXmlValue  value 
) [protected]

Protected constructor (internal).

Creates a new attribute. Doesn't verify if the attribute name already exists in parent element

Parameters:
parent CXmlElement*, parent element (can't be NULL)
name const char*, attribute name
value CXmlValue, attribute value


Member Function Documentation

virtual void sptk::CXmlAttribute::value ( const char *  new_value  )  [inline, virtual]

Sets new value to node.

Parameters:
new_value const char *, value to set
See also:
value()

Reimplemented from sptk::CXmlNode.

References m_value.

virtual void sptk::CXmlAttribute::value ( const std::string &  new_value  )  [inline, virtual]

Sets new value to node.

Parameters:
new_value const std::string &, new value
See also:
value()

Reimplemented from sptk::CXmlNode.

References m_value.


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

Mon Mar 5 11:56:21 2012: SPTK 3.5.7