IN2OSM
1.0.1
|
#include <rapidxml.hpp>
Public Member Functions | |
xml_attribute () | |
xml_document< Ch > * | document () const |
xml_attribute< Ch > * | previous_attribute (const Ch *name=0, std::size_t name_size=0, bool case_sensitive=true) const |
xml_attribute< Ch > * | next_attribute (const Ch *name=0, std::size_t name_size=0, bool case_sensitive=true) const |
Ch * | name () const |
void | name (const Ch *name, std::size_t size) |
void | name (const Ch *name) |
std::size_t | name_size () const |
Ch * | value () const |
void | value (const Ch *value, std::size_t size) |
void | value (const Ch *value) |
std::size_t | value_size () const |
xml_node< Ch > * | parent () const |
Static Protected Member Functions | |
static Ch * | nullstr () |
Protected Attributes | |
Ch * | m_name |
Ch * | m_value |
std::size_t | m_name_size |
std::size_t | m_value_size |
xml_node< Ch > * | m_parent |
Private Attributes | |
xml_attribute< Ch > * | m_prev_attribute |
xml_attribute< Ch > * | m_next_attribute |
Friends | |
class | xml_node< Ch > |
Class representing attribute node of XML document. Each attribute has name and value strings, which are available through name() and value() functions (inherited from xml_base). Note that after parse, both name and value of attribute will point to interior of source text used for parsing. Thus, this text must persist in memory for the lifetime of attribute.
Ch | Character type to use. |
Definition at line 138 of file rapidxml.hpp.
|
inline |
Constructs an empty attribute with the specified type. Consider using memory_pool of appropriate xml_document if allocating attributes manually.
Definition at line 810 of file rapidxml.hpp.
|
inline |
Gets document of which attribute is a child.
Definition at line 819 of file rapidxml.hpp.
|
inlineinherited |
Gets name of the node. Interpretation of name depends on type of node. Note that name will not be zero-terminated if rapidxml::parse_no_string_terminators option was selected during parse.
Use name_size() function to determine length of the name.
Definition at line 673 of file rapidxml.hpp.
|
inlineinherited |
Sets name of node to a non zero-terminated string. See ownership_of_strings.
Note that node does not own its name or value, it only stores a pointer to it. It will not delete or otherwise free the pointer on destruction. It is reponsibility of the user to properly manage lifetime of the string. The easiest way to achieve it is to use memory_pool of the document to allocate the string - on destruction of the document the string will be automatically freed.
Size of name must be specified separately, because name does not have to be zero terminated. Use name(const Ch *) function to have the length automatically calculated (string must be zero terminated).
name | Name of node to set. Does not have to be zero terminated. |
size | Size of name, in characters. This does not include zero terminator, if one is present. |
Definition at line 721 of file rapidxml.hpp.
|
inlineinherited |
Sets name of node to a zero-terminated string. See also ownership_of_strings and xml_node::name(const Ch *, std::size_t).
name | Name of node to set. Must be zero terminated. |
Definition at line 730 of file rapidxml.hpp.
|
inlineinherited |
Gets size of node name, not including terminator character. This function works correctly irrespective of whether name is or is not zero terminated.
Definition at line 681 of file rapidxml.hpp.
|
inline |
Gets next attribute, optionally matching attribute name.
name | Name of attribute to find, or 0 to return next attribute regardless of its name; this string doesn't have to be zero-terminated if name_size is non-zero |
name_size | Size of name, in characters, or 0 to have size calculated automatically from string |
case_sensitive | Should name comparison be case-sensitive; non case-sensitive comparison works properly only for ASCII characters |
Definition at line 856 of file rapidxml.hpp.
|
inlinestaticprotectedinherited |
Definition at line 778 of file rapidxml.hpp.
|
inlineinherited |
Gets node parent.
Definition at line 770 of file rapidxml.hpp.
|
inline |
Gets previous attribute, optionally matching attribute name.
name | Name of attribute to find, or 0 to return previous attribute regardless of its name; this string doesn't have to be zero-terminated if name_size is non-zero |
name_size | Size of name, in characters, or 0 to have size calculated automatically from string |
case_sensitive | Should name comparison be case-sensitive; non case-sensitive comparison works properly only for ASCII characters |
Definition at line 836 of file rapidxml.hpp.
|
inlineinherited |
Gets value of node. Interpretation of value depends on type of node. Note that value will not be zero-terminated if rapidxml::parse_no_string_terminators option was selected during parse.
Use value_size() function to determine length of the value.
Definition at line 692 of file rapidxml.hpp.
|
inlineinherited |
Sets value of node to a non zero-terminated string. See ownership_of_strings.
Note that node does not own its name or value, it only stores a pointer to it. It will not delete or otherwise free the pointer on destruction. It is reponsibility of the user to properly manage lifetime of the string. The easiest way to achieve it is to use memory_pool of the document to allocate the string - on destruction of the document the string will be automatically freed.
Size of value must be specified separately, because it does not have to be zero terminated. Use value(const Ch *) function to have the length automatically calculated (string must be zero terminated).
If an element has a child node of type node_data, it will take precedence over element value when printing. If you want to manipulate data of elements using values, use parser flag rapidxml::parse_no_data_nodes to prevent creation of data nodes by the parser.
value | value of node to set. Does not have to be zero terminated. |
size | Size of value, in characters. This does not include zero terminator, if one is present. |
Definition at line 751 of file rapidxml.hpp.
|
inlineinherited |
Sets value of node to a zero-terminated string. See also ownership_of_strings and xml_node::value(const Ch *, std::size_t).
value | Vame of node to set. Must be zero terminated. |
Definition at line 760 of file rapidxml.hpp.
|
inlineinherited |
Gets size of node value, not including terminator character. This function works correctly irrespective of whether value is or is not zero terminated.
Definition at line 700 of file rapidxml.hpp.
|
friend |
Definition at line 801 of file rapidxml.hpp.
|
protectedinherited |
Definition at line 784 of file rapidxml.hpp.
|
protectedinherited |
Definition at line 786 of file rapidxml.hpp.
|
private |
Definition at line 874 of file rapidxml.hpp.
|
protectedinherited |
Definition at line 788 of file rapidxml.hpp.
|
private |
Definition at line 873 of file rapidxml.hpp.
|
protectedinherited |
Definition at line 785 of file rapidxml.hpp.
|
protectedinherited |
Definition at line 787 of file rapidxml.hpp.