|
ADS-IDAC Engine 5.0.0
|
Classes | |
| struct | Attribute |
| One attribute of an element. More... | |
| struct | Element |
| One XML element with its attributes and child elements. More... | |
| class | XmlError |
| Exception thrown by parse() and parseFile(). More... | |
Functions | |
| Element | parse (const std::string &text) |
| Element | parseFile (const std::string &path) |
| Element faulttree::xml::parse | ( | const std::string & | text | ) |
Parses a document held in memory. Throws XmlError on malformed input.
The document is an optional <?xml ...?> declaration, then exactly one root element. Whitespace and comments may appear before, between and after elements. Attribute values must be quoted with single or double quotes and must not contain <. The entities &, <, >, " and ' are decoded, as are decimal (A) and hexadecimal (A) character references up to 0x7F.
| text | Complete XML document. |
| XmlError | if there is no root element, a tag, attribute, comment or declaration is unterminated, a closing tag does not match, content follows the root element, an entity is unknown or a character reference is above 0x7F, or the text uses DOCTYPE, CDATA or a processing instruction. |
Definition at line 259 of file xml_lite.cpp.
Referenced by RestApiSolver::createSession(), parseFile(), faulttree::parseFtaString(), RestApiSolver::populateR5Pars(), RestApiSolver::restore(), and RestApiSolver::runSequence().
| Element faulttree::xml::parseFile | ( | const std::string & | path | ) |
Reads and parses a file. Throws XmlError if the file cannot be read.
The file is opened in binary mode and read completely before parsing.
| path | Path of the file. |
Definition at line 261 of file xml_lite.cpp.
References parse().
Referenced by faulttree::parseFtaFile().