#include <XML.hpp>
Public Member Functions | |
| XMLFile (const std::string &filename, const std::string &rootNodeName, Logger *pLogger) | |
| Constructor. | |
| ~XMLFile () | |
| Destructor. | |
| bool | load () |
| Load the XML file. | |
| bool | save () |
| Save the XML file. | |
| void | clear () |
| Clear the XML file. | |
| XMLNode * | getRootNode () const |
| Get root node. | |
| const std::string | getLastError () const |
| Get last error. | |
| const int | getLastErrorLine () const |
| Get last error line number. | |
| const int | getLastErrorColumn () const |
| Get last error line number. | |
Private Attributes | |
| Logger * | m_pLogger |
| Pointer to the logger to be used. | |
| std::string | m_filename |
| XML filename. | |
| std::string | m_rootNodeName |
| XML root node name. | |
| XMLNode * | m_pRootNode |
| XML root node. | |
| TiXmlDocument * | m_pXMLDocument |
| TinyXML: XML document. | |
| TiXmlElement * | m_pXMLRoot |
| TinyXML: XML root element. | |
| std::string | m_lastError |
| Description of last error. | |
| int | m_lastErrorLine |
| Line number of last error. | |
| int | m_lastErrorColumn |
| Column of last error. | |
| syBR::Core::XMLFile::XMLFile | ( | const std::string & | filename, | |
| const std::string & | rootNodeName, | |||
| Logger * | pLogger | |||
| ) |
Constructor.
| filename | Name of the XML file to be used | |
| rootNodeName | Name of the root node of the XML file | |
| pLogger | Pointer to the instance of the logger to use |
| syBR::Core::XMLFile::~XMLFile | ( | ) |
Destructor.
| bool syBR::Core::XMLFile::load | ( | ) |
Load the XML file.
| bool syBR::Core::XMLFile::save | ( | ) |
Save the XML file.
| void syBR::Core::XMLFile::clear | ( | ) |
Clear the XML file.
| XMLNode * syBR::Core::XMLFile::getRootNode | ( | ) | const |
Get root node.
NULL will be returned if the XML file has not been initialized / loaded.
| const std::string syBR::Core::XMLFile::getLastError | ( | ) | const |
Get last error.
| const int syBR::Core::XMLFile::getLastErrorLine | ( | ) | const |
Get last error line number.
| const int syBR::Core::XMLFile::getLastErrorColumn | ( | ) | const |
Get last error line number.
Logger* syBR::Core::XMLFile::m_pLogger [private] |
Pointer to the logger to be used.
std::string syBR::Core::XMLFile::m_filename [private] |
XML filename.
std::string syBR::Core::XMLFile::m_rootNodeName [private] |
XML root node name.
XMLNode* syBR::Core::XMLFile::m_pRootNode [private] |
XML root node.
TiXmlDocument* syBR::Core::XMLFile::m_pXMLDocument [private] |
TinyXML: XML document.
TiXmlElement* syBR::Core::XMLFile::m_pXMLRoot [private] |
TinyXML: XML root element.
std::string syBR::Core::XMLFile::m_lastError [private] |
Description of last error.
int syBR::Core::XMLFile::m_lastErrorLine [private] |
Line number of last error.
int syBR::Core::XMLFile::m_lastErrorColumn [private] |
Column of last error.
Copyright © 2008 by Sebastien Frippiat

This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License.
Last modified Tue Dec 30 17:57:33 2008