#include <xmlnode.h>
Inheritance diagram for freedaisy::XMLNode:
Public Member Functions | |
| XMLNode () | |
| Create an empty XMLNode. | |
| XMLNode (std::string name) | |
| Create an empty XMLNode with a node name. | |
| XMLNode (xmlNodePtr src) | |
| Create an XMLNode from a xmlNodePtr. | |
| XMLNode (XMLNode *src) | |
| Create an XMLNode from an XMLNode. | |
| std::string | operator[] (std::string attr) |
| Get an attribute using the operator []. | |
| std::string | getName () |
| Get the node name. | |
| std::string | getContent () |
| Get the node content. | |
| void | setContent (std::string content) |
| Set the node content. | |
| int | hasAttr (std::string name) |
| std::string | getAttr (std::string name) |
| Get an attribute. | |
| void | setAttr (std::string name, std::string attr) |
| Set an attribute. | |
| void | addChild (XMLNode *cur) |
| Add a child. | |
| std::vector< XMLNode > | getChildren () |
| Get children. | |
| std::vector< XMLNode > | getNextNodes (bool withme=false) |
| Get next nodes. | |
| XMLNode | getParent () |
| Get parent. | |
| void | unlink () |
| Unlink a node. | |
| xmlNodePtr | getC () |
| Gets the C xmlNodePtr object. | |
Protected Attributes | |
| xmlNodePtr | _xmlnode |
| libxml2 object | |
Definition at line 12 of file xmlnode.h.
|
|
Create an XMLNode from an XMLNode. This is useful for derivated classes Definition at line 19 of file xmlnode.cpp. |
|
|
Get an attribute.
Definition at line 47 of file xmlnode.cpp. References _xmlnode. Referenced by freedaisy::Meta::getContent(), freedaisy::Link::getHref(), freedaisy::Meta::getName(), freedaisy::Meta::getScheme(), and operator[](). |
|
|
Get next nodes.
Definition at line 65 of file xmlnode.cpp. |
|
|
Get an attribute using the operator []. Example : std::cout << node["href"] << std::endl; // Prints the href attribute Definition at line 23 of file xmlnode.cpp. References getAttr(). |
|
||||||||||||
|
Set an attribute.
Definition at line 51 of file xmlnode.cpp. References _xmlnode. Referenced by freedaisy::SMIL::createDoc(), freedaisy::NCC::createDoc(), freedaisy::Discinfo::createDoc(), freedaisy::Meta::setContent(), freedaisy::Link::setHref(), freedaisy::NCC::setLang(), freedaisy::Discinfo::setLang(), freedaisy::Meta::setName(), and freedaisy::Meta::setScheme(). |
|
|
Set the node content.
Reimplemented in freedaisy::Meta. Definition at line 35 of file xmlnode.cpp. References _xmlnode. Referenced by freedaisy::NCC::createDoc(), freedaisy::Discinfo::createDoc(), and freedaisy::NCC::setTitle(). |
1.4.6