42 #ifndef Teuchos_TREEBUILDINGXMLHANDLER_H 43 #define Teuchos_TREEBUILDINGXMLHANDLER_H 63 typedef Teuchos::map<std::string, std::string> Map;
74 ,
"Error, An empty XML std::string or file was specified!" 75 " The XML specification requires at minimum the presence" 76 " of a root element!" );
88 const Map& attributes);
93 std::stack<XMLObject> path_;
void characters(const std::string &chars)
Process character data.
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
Macro for throwing an exception with breakpointing to ease debugging.
const XMLObject & getChild(int i) const
Return the i-th child node.
Teuchos header file which uses auto-configuration information to include necessary C++ headers...
int endElement(const std::string &tag)
Receive notification of the end of an element.
Thrown when attempting to parse an empty XML std::string.
bool isEmpty() const
Find out if a node is empty.
Representation of an XML data tree. XMLObject is a ref-counted handle to a XMLObjectImplem object...
TreeBuildingXMLHandler()
Empty constructor.
void startElement(const std::string &tag, const Map &attributes)
Receive notification of the start of an element.
The Teuchos namespace contains all of the classes, structs and enums used by Teuchos, as well as a number of utility routines.
const XMLObject & getObject() const
Retrieve the entire XML tree.
TreeBuildingXMLHandler assembles a XMLObject from your XML input.
An object representation of a subset of XML data.