#include <xml_manager.h>
Collaboration diagram for GNUMessenger::XMLManager:

Public Member Functions | |
| XMLManager (const string &directory="") | |
| ~XMLManager () | |
| Destructor. | |
| bool | createNew (const string &username, const VBuffer &password) |
| Creates new XML config file on disk for specified user and logs that user into the system. | |
| bool | login (const string &username, const VBuffer &password) |
| Tries to log the specified user in. | |
| bool | logout () |
| Saves and closes the configuration for a user. | |
| string | getFileName (const string &username) const |
| Return the encoded file name for given user name. | |
| bool | commit () |
| Writes configuration to disk. | |
| bool | setPassword (const VBuffer &password) |
| Sets active password for loged-in user. | |
| string | getLogin () const |
| Returns loged-in username. | |
| bool | isOK () |
| Returns wether someone is logged in or not. | |
| string | encode (const string &inbound) |
| Replace HTML formated unfriendly sequences with original sequence. | |
| string | decode (const string &inbound) |
| Replace HTML/XML unfriendlies with HTML codes. | |
| XMLNode & | returnXML () |
| ContactManager & | contacts () |
| SettingsManager & | settings () |
Static Public Member Functions | |
| bool | setDirectory (const string &dir) |
| Sets the directory that configs are stored in. | |
| const string & | getDirectory () |
| Returns the current directory used to store configurations. | |
| bool | search (const string &dataToFind, const string &tagName, XMLNode &parentNode, XMLNode &returnNode) |
| Static XML searching algo, assigns a node by reference as return. | |
| bool | baseSearch (const string &dataToFind, const string &tagName, XMLNode &parentNode, XMLNode &realParent, unsigned int &num) |
| Same as regular search but the parent of the search term is returned. | |
| unsigned int | tagCount (const string &findType, const XMLNode &parentNode) |
| Counts all tags of certain type in a XML node, recursive underbelly. | |
| void | getAllTags (const string &findType, XMLNode &parentNode, vector< XMLNode > &result_vector) |
| Returns a vector of all tags. | |
| string | printTree (const XMLNode &base) |
| Returns a string of the XML tree in text form. | |
| bool | exists (const string &username) |
| Checks to see if a given user has a configuration. | |
| bool | isDirectory (const string &dirname) |
The XML Manager also controls authentication of users and encryption/decryption of disk-based settings.
Definition at line 41 of file xml_manager.h.
|
|
Writes configuration to disk.
Referenced by createNew(), logout(), and setPassword().
|
|
||||||||||||
|
Creates new XML config file on disk for specified user and logs that user into the system.
References commit(), exists(), getFileName(), logout(), GNUMessenger::XMLNode::setName(), and GNUMessenger::XMLNode::setProperty().
Here is the call graph for this function: ![]() |
|
|
Checks to see if a given user has a configuration.
Referenced by createNew(), and login().
|
|
||||||||||||
|
Tries to log the specified user in.
References exists(), getFileName(), and logout().
Here is the call graph for this function: ![]() |
|
|
Saves and closes the configuration for a user.
References commit(), and GNUMessenger::VBuffer::wipe(). Referenced by createNew(), and login().
Here is the call graph for this function: ![]() |
|
|
Sets the directory that configs are stored in.
|
1.3.8