#include <DomParserCommon.H>
Public Member Functions | |
DomParserCommon () | |
Constructor. | |
~DomParserCommon () | |
Destructor. | |
void | enable_validation (const string &schemas_dir=SCHEMASDIR) |
Enable Validation. | |
void | disable_validation () |
Disable Validation. | |
Static Public Member Functions | |
static string | str_transcode (const XMLCh *const to_transcode) |
Transcodes a XMLCh to string. | |
Protected Member Functions | |
DOMNode * | parse (const string &xml_payload) |
Do the actual parsing of the XML document. | |
void | fill_postal_info (DOMNode *n, PostalInfo *postal_info) |
Fills a Postal Info struct. | |
void | fill_ds_info (DOMNode *n, DSInfo *ds_info) |
Fills a DSInfo object. | |
map< string, string, less < string > > | get_children_simple (DOMNode *n) |
Fills a map of children names with associated content text. | |
map< string, string, less < string > > | get_attributes (DOMNode *n) |
Fills a map of attributes and associated values. | |
Protected Attributes | |
XercesDOMParser * | _parser |
Object for parsing XML documents. | |
DomErrorHandler | _error_handler |
DOM error handler. |
void DomParserCommon::enable_validation | ( | const string & | schemas_dir = SCHEMASDIR |
) |
Enable Validation.
schemas_dir | Path to the schemas directory |
void DomParserCommon::fill_ds_info | ( | DOMNode * | n, | |
DSInfo * | ds_info | |||
) | [protected] |
void DomParserCommon::fill_postal_info | ( | DOMNode * | n, | |
PostalInfo * | postal_info | |||
) | [protected] |
Fills a Postal Info struct.
n | Pointer to a node of the document tree | |
postal_info | Pointer to a postal info struct |
map< string, string, less<string> > DomParserCommon::get_attributes | ( | DOMNode * | n | ) | [protected] |
Fills a map of attributes and associated values.
n | Pointer to a node of the document tree |
map< string, string, less<string> > DomParserCommon::get_children_simple | ( | DOMNode * | n | ) | [protected] |
Fills a map of children names with associated content text.
n | Pointer to a node of the document tree |
DOMNode* DomParserCommon::parse | ( | const string & | xml_payload | ) | [protected] |
Do the actual parsing of the XML document.
xml_payload | XML to be parsed |
static string DomParserCommon::str_transcode | ( | const XMLCh *const | to_transcode | ) | [static] |
Transcodes a XMLCh to string.
to_transcode | String to be transcoded |