33 #include "BESXMLGetDataDDXCommand.h" 34 #include "BESDefinitionStorageList.h" 35 #include "BESDefinitionStorage.h" 36 #include "BESDefine.h" 37 #include "BESDapNames.h" 38 #include "BESResponseNames.h" 39 #include "BESXMLUtils.h" 41 #include "BESSyntaxUserError.h" 59 map<string, string> props;
62 if (name != GET_RESPONSE) {
63 string err =
"The specified command " + name +
" is not a get command";
67 string type = props[
"type"];
68 if (type.empty() || type != DATADDX_SERVICE) {
69 string err = name +
" command: data product must be " + DATADDX_SERVICE;
73 parse_basic_get(node, name, type, value, props);
76 map<string, string> cprops;
81 while (cnode && (elems < 2)) {
82 if (cname ==
"contentStartId") {
83 if (!_contentStartId.empty()) {
84 string err = name +
" command: contentStartId has multiple values";
87 _contentStartId = cval;
88 _str_cmd +=
" contentStartId " + _contentStartId;
91 if (cname ==
"mimeBoundary") {
92 if (!_mimeBoundary.empty()) {
93 string err = name +
" command: mimeBoundary has multiple values";
97 _str_cmd +=
" mimeBoundary " + _mimeBoundary;
103 if (_contentStartId.empty()) {
104 string err = name +
" command: contentStartId not specified";
107 if (_mimeBoundary.empty()) {
108 string err = name +
" command: mimeBoundary not specified";
126 _dhi.
data[DATADDX_STARTID] = _contentStartId;
127 _dhi.
data[DATADDX_BOUNDARY] = _mimeBoundary;
138 strm << BESIndent::LMarg <<
"BESXMLGetDataDDXCommand::dump - (" << (
void *)
this <<
")" << endl;
141 BESIndent::UnIndent();
static xmlNode * GetFirstChild(xmlNode *node, string &child_name, string &child_value, map< string, string > &child_props)
get the first element child node for the given node
virtual void dump(ostream &strm) const
dumps information about this object
static xmlNode * GetNextChild(xmlNode *child_node, string &next_name, string &next_value, map< string, string > &next_props)
get the next element child node after the given child node
virtual void prep_request()
prepare the get dataddx command
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 set_response()
The request has been parsed, use the command action name to set the response handler.
virtual void prep_request()
Prepare any information needed to execute the request of this get command.
Structure storing information used by the BES to handle the request.
virtual void parse_request(xmlNode *node)
parse a get dataddx command.
map< string, string > data
the map of string data that will be required for the current request.
virtual void dump(ostream &strm) const
dumps information about this object