26 #include "ShowPathInfoCommand.h" 27 #include "BESDataNames.h" 30 #include "BESXMLUtils.h" 31 #include "BESSyntaxUserError.h" 33 #define SPI_DEBUG_KEY "show-path-info" 35 #define SHOW_PATH_INFO_RESPONSE "show.pathInfo" 54 map<string, string> props;
56 if (name != SHOW_PATH_INFO_RESPONSE_STR) {
57 string err =
"The specified command " + name +
" is not a " + SHOW_PATH_INFO_RESPONSE_STR +
" command";
62 d_xmlcmd_dhi.action = SHOW_PATH_INFO_RESPONSE;
63 d_xmlcmd_dhi.data[SHOW_PATH_INFO_RESPONSE] = SHOW_PATH_INFO_RESPONSE;
64 d_cmd_log_info =
"show pathInfo";
67 d_xmlcmd_dhi.data[CONTAINER] = props[
"node"];
68 if (!d_xmlcmd_dhi.data[CONTAINER].empty()) {
69 d_cmd_log_info +=
" for " + d_xmlcmd_dhi.data[CONTAINER];
71 d_cmd_log_info +=
";";
73 BESDEBUG(SPI_DEBUG_KEY,
"Built BES Command: '" << d_cmd_log_info <<
"'"<< endl );
88 strm << BESIndent::LMarg <<
"ShowPathInfoCommand::dump - (" << (
void *)
this <<
")" << endl;
91 BESIndent::UnIndent();
virtual void dump(ostream &strm) const
dumps information about this object
static void GetNodeInfo(xmlNode *node, string &name, string &value, map< string, string > &props)
get the name, value if any, and any properties for the specified node
error thrown if there is a user syntax error in the request or any other user error
virtual void parse_request(xmlNode *node)
parse a show command. No properties or children elements
virtual void set_response()
The request has been parsed, use the command action name to set the response handler.
virtual void dump(ostream &strm) const
dumps information about this object
Structure storing information used by the BES to handle the request.
Base class for the BES's commands.