34#define BESXMLUtils_h_ 1
40#include <libxml/encoding.h>
41#include <libxml/tree.h>
47 virtual ~BESXMLUtils();
49 static void XMLErrorFunc(
void *context,
const char *msg, ...);
50 static void GetProps(xmlNode *node, std::map<std::string, std::string> &props);
51 static void GetNodeInfo(xmlNode *node, std::string &name, std::string &value, std::map<std::string, std::string> &props);
52 static xmlNode *
GetFirstChild(xmlNode *node, std::string &child_name, std::string &child_value,
53 std::map<std::string, std::string> &child_props);
54 static xmlNode *
GetNextChild(xmlNode *child_node, std::string &next_name, std::string &next_value,
55 std::map<std::string, std::string> &next_props);
56 static xmlNode *
GetChild(xmlNode *node,
const std::string &child_name, std::string &child_value,
57 std::map<std::string, std::string> &child_props);
static void GetNodeInfo(xmlNode *node, std::string &name, std::string &value, std::map< std::string, std::string > &props)
get the name, value if any, and any properties for the specified node
static void GetProps(xmlNode *node, std::map< std::string, std::string > &props)
given an xml node, build the map of properties (xml attributes) for that node
static xmlNode * GetFirstChild(xmlNode *node, std::string &child_name, std::string &child_value, std::map< std::string, std::string > &child_props)
get the first element child node for the given node
static xmlNode * GetChild(xmlNode *node, const std::string &child_name, std::string &child_value, std::map< std::string, std::string > &child_props)
get the element child node of the given node with the given name
static xmlNode * GetNextChild(xmlNode *child_node, std::string &next_name, std::string &next_value, std::map< std::string, std::string > &next_props)
get the next element child node after the given child node
static void XMLErrorFunc(void *context, const char *msg,...)
error function used by libxml2 to report errors