![]() |
AppEasy Core SDK
1.5.0
Cross platform mobile and desktop app and game development SDK - The easy way to make apps
|
An Xml node, e.g. <XmlNode></XmlNode> More...
#include <CzXml.h>
Public Types | |
| typedef CzXmlNodeList::iterator | _Iterator |
| typedef CzXmlAttributeList::iterator | _AttribIterator |
Public Member Functions | |
| _Iterator | begin () |
| _Iterator | end () |
| _AttribIterator | attribs_begin () |
| _AttribIterator | attribs_end () |
| CzXmlNode () | |
| virtual | ~CzXmlNode () |
| void | Clear () |
| void | AddChild (CzXmlNode *node) |
| void | RemoveChild (CzXmlNode *node) |
| void | AddAttribute (CzXmlAttribute *attribute) |
| Adds an attribute to this node. | |
| void | AddAttribute (const CzString &name, const CzString &value, CzXmlParser *parser) |
| Adds an attribute to this node. | |
| void | AddAttribute (const CzString &name, const char *value, CzXmlParser *parser) |
| Adds an attribute to this node. | |
| void | UpdateAttribute (const CzString &name, const char *value, CzXmlParser *parser) |
| Updates an existing named attribute in this node. | |
| void | SetName (const char *name) |
| void | SetName (const char *name, int len) |
| void | SetValue (const char *value) |
| void | SetValue (const char *value, int len) |
| const CzString & | GetName () const |
| Gets the nodes name. | |
| const CzString & | getValue () const |
| Gets the nodes value. | |
| int | getValueAsInt () const |
| Gets the nodes value as an integer. | |
| float | getValueAsFloat () const |
| Gets the nodes value as a floating point number. | |
| bool | getValueAsBool () const |
| Gets the nodes value as a boolean. | |
| CzXmlParser * | getParser () |
| Returns the parser that created this node. | |
| void | setParser (CzXmlParser *parser) |
| Sets the parser that created this node. | |
| void | PrintAttributes (CzString &out) |
| Print node attributes to a string. | |
| void | PrintTree (CzString &out, int level=0) |
| Print entire tree to a string. | |
| CzXmlNode * | getFirstNode () |
| Get first child node. | |
| CzXmlNode * | getFirstNamedNode (unsigned int name_hash) |
| Get first occurrence of a node in this node and all children. | |
| void | getNamedNodes (unsigned int name_hash, CzXmlNodeList *nodes) |
| Get all occurrences of a node in this node and all children. | |
| int | getAttributeCount () const |
| Returns number of attributes that the node contains. | |
| CzXmlAttribute * | getAttribute (const char *name) |
| Returns named attribute. | |
| CzXmlAttribute * | getAttribute (unsigned int hash) |
| Returns named attribute. | |
| CzXmlAttribute * | getAttributeAtInex (int index) |
| Returns attribute at the specified index. | |
| int | SaveAttributes (CzFile *file) |
| Saves the attributes to a file. | |
| int | SaveTree (CzFile *file, int level=0) |
| Saves entire node tree to a file. | |
| int | Save (const char *filename) |
| Saves entire node tree to a file with the specified filename. | |
| const char * | getParserFileName () const |
| Returns the name of the file that is being parsed. | |
| void | ToLower (bool recursive) |
| Changes tags and attributes names to lower case, does not affect values. | |
| void | ToUpper (bool recursive) |
| Changes tags and attributes names to upper case, does not affect values. | |
| CzXmlNode * | Clone (CzXmlNode *parent) |
| Clones this node. | |
| CzXmlNode * | CloneTree (CzXmlNode *parent) |
| Clones the entire tree. | |
Public Attributes | |
| bool | Managed |
| Managec nodes are managed by the pools system and should not be deleted. | |
| bool | HasValue |
| Determines if value is valid. | |
| uint16 | Line |
| File line. | |
| CzString | Name |
| Node name. | |
| CzString | Value |
| Node value. | |
| CzXmlAttributeList | Attributes |
| List of attributes associated with this node. | |
| CzXmlNode * | Parent |
| Parent node. | |
| CzXmlNodeList | Children |
| List of children nodes. | |
| CzXmlParser * | Parser |
| Parser that created this node. | |
An Xml node, e.g. <XmlNode></XmlNode>
| typedef CzXmlAttributeList::iterator CzXmlNode::_AttribIterator |
| typedef CzXmlNodeList::iterator CzXmlNode::_Iterator |
| CzXmlNode::CzXmlNode | ( | ) | [inline] |
| CzXmlNode::~CzXmlNode | ( | ) | [virtual] |
| void CzXmlNode::AddAttribute | ( | CzXmlAttribute * | attribute | ) |
Adds an attribute to this node.
| void CzXmlNode::AddAttribute | ( | const CzString & | name, |
| const CzString & | value, | ||
| CzXmlParser * | parser | ||
| ) |
Adds an attribute to this node.
| void CzXmlNode::AddAttribute | ( | const CzString & | name, |
| const char * | value, | ||
| CzXmlParser * | parser | ||
| ) |
Adds an attribute to this node.
| void CzXmlNode::AddChild | ( | CzXmlNode * | node | ) | [inline] |
| node | Adds a child node to the tree |
| _AttribIterator CzXmlNode::attribs_begin | ( | ) | [inline] |
| _AttribIterator CzXmlNode::attribs_end | ( | ) | [inline] |
| _Iterator CzXmlNode::begin | ( | ) | [inline] |
| void CzXmlNode::Clear | ( | ) | [inline] |
| CzXmlNode * CzXmlNode::Clone | ( | CzXmlNode * | parent | ) |
Clones this node.
| CzXmlNode * CzXmlNode::CloneTree | ( | CzXmlNode * | parent | ) |
Clones the entire tree.
| _Iterator CzXmlNode::end | ( | ) | [inline] |
| CzXmlAttribute * CzXmlNode::getAttribute | ( | const char * | name | ) |
Returns named attribute.
| CzXmlAttribute * CzXmlNode::getAttribute | ( | unsigned int | hash | ) |
Returns named attribute.
| CzXmlAttribute * CzXmlNode::getAttributeAtInex | ( | int | index | ) |
Returns attribute at the specified index.
| int CzXmlNode::getAttributeCount | ( | ) | const [inline] |
Returns number of attributes that the node contains.
| CzXmlNode * CzXmlNode::getFirstNamedNode | ( | unsigned int | name_hash | ) |
Get first occurrence of a node in this node and all children.
Get first child node.
| const CzString& CzXmlNode::GetName | ( | ) | const [inline] |
Gets the nodes name.
| void CzXmlNode::getNamedNodes | ( | unsigned int | name_hash, |
| CzXmlNodeList * | nodes | ||
| ) |
Get all occurrences of a node in this node and all children.
| CzXmlParser* CzXmlNode::getParser | ( | ) | [inline] |
Returns the parser that created this node.
| const char * CzXmlNode::getParserFileName | ( | ) | const |
Returns the name of the file that is being parsed.
| const CzString& CzXmlNode::getValue | ( | ) | const [inline] |
Gets the nodes value.
| bool CzXmlNode::getValueAsBool | ( | ) | const |
Gets the nodes value as a boolean.
| float CzXmlNode::getValueAsFloat | ( | ) | const |
Gets the nodes value as a floating point number.
| int CzXmlNode::getValueAsInt | ( | ) | const |
Gets the nodes value as an integer.
| void CzXmlNode::PrintAttributes | ( | CzString & | out | ) |
Print node attributes to a string.
| void CzXmlNode::PrintTree | ( | CzString & | out, |
| int | level = 0 |
||
| ) |
Print entire tree to a string.
| void CzXmlNode::RemoveChild | ( | CzXmlNode * | node | ) | [inline] |
| node | Remove a child node from the tree (does not destroy it) |
| int CzXmlNode::Save | ( | const char * | filename | ) |
Saves entire node tree to a file with the specified filename.
| int CzXmlNode::SaveAttributes | ( | CzFile * | file | ) |
Saves the attributes to a file.
| int CzXmlNode::SaveTree | ( | CzFile * | file, |
| int | level = 0 |
||
| ) |
Saves entire node tree to a file.
| void CzXmlNode::SetName | ( | const char * | name | ) | [inline] |
| name | Sets the nodes name |
| void CzXmlNode::SetName | ( | const char * | name, |
| int | len | ||
| ) | [inline] |
| len | Sets the nodes name |
| void CzXmlNode::setParser | ( | CzXmlParser * | parser | ) | [inline] |
Sets the parser that created this node.
| void CzXmlNode::SetValue | ( | const char * | value | ) | [inline] |
| value | Sets the nodes value |
| void CzXmlNode::SetValue | ( | const char * | value, |
| int | len | ||
| ) | [inline] |
| len | Sets the nodes value |
| void CzXmlNode::ToLower | ( | bool | recursive | ) |
Changes tags and attributes names to lower case, does not affect values.
| void CzXmlNode::ToUpper | ( | bool | recursive | ) |
Changes tags and attributes names to upper case, does not affect values.
| void CzXmlNode::UpdateAttribute | ( | const CzString & | name, |
| const char * | value, | ||
| CzXmlParser * | parser | ||
| ) |
Updates an existing named attribute in this node.
List of attributes associated with this node.
List of children nodes.
| bool CzXmlNode::HasValue |
Determines if value is valid.
| uint16 CzXmlNode::Line |
File line.
| bool CzXmlNode::Managed |
Managec nodes are managed by the pools system and should not be deleted.
Node name.
Parent node.
Parser that created this node.
Node value.