#include <BESGetCommand.h>
Public Member Functions | |
BESGetCommand (const string &cmd) | |
virtual void | dump (ostream &strm) const |
dumps information about this object | |
virtual string | parse_options (BESTokenizer &tokens, BESDataHandlerInterface &dhi) |
virtual BESResponseHandler * | parse_request (BESTokenizer &tokens, BESDataHandlerInterface &dhi) |
knows how to parse a get request | |
virtual | ~BESGetCommand () |
Static Public Member Functions | |
static void | add_command (const string &cmd_str, BESCommand *cmd) |
static bool | del_command (const string &cmd_str) |
static BESCommand * | find_command (const string &cmd_str) |
Static Public Attributes | |
static BESCommand * | TermCommand = new BESTermCommand( "term" ) |
Protected Attributes | |
string | _cmd |
Definition at line 38 of file BESGetCommand.h.
BESGetCommand::BESGetCommand | ( | const string & | cmd | ) | [inline] |
Definition at line 43 of file BESGetCommand.h.
virtual BESGetCommand::~BESGetCommand | ( | ) | [inline, virtual] |
Definition at line 45 of file BESGetCommand.h.
void BESCommand::add_command | ( | const string & | cmd_str, | |
BESCommand * | cmd | |||
) | [static, inherited] |
Definition at line 49 of file BESCommand.cc.
Referenced by DAPCommandModule::initialize(), and BESDefaultCommands::initialize().
bool BESCommand::del_command | ( | const string & | cmd_str | ) | [static, inherited] |
Definition at line 55 of file BESCommand.cc.
Referenced by DAPCommandModule::terminate(), and BESDefaultCommands::terminate().
void BESGetCommand::dump | ( | ostream & | strm | ) | const [virtual] |
dumps information about this object
Displays the pointer value of this instance
strm | C++ i/o stream to dump the information to |
Reimplemented from BESCommand.
Definition at line 179 of file BESGetCommand.cc.
References BESIndent::Indent(), BESIndent::LMarg(), and BESIndent::UnIndent().
BESCommand * BESCommand::find_command | ( | const string & | cmd_str | ) | [static, inherited] |
Definition at line 75 of file BESCommand.cc.
Referenced by BESCmdParser::parse(), BESShowCommand::parse_request(), BESSetCommand::parse_request(), parse_request(), BESDeleteCommand::parse_request(), and BESDefineCommand::parse_request().
string BESCommand::parse_options | ( | BESTokenizer & | tokens, | |
BESDataHandlerInterface & | dhi | |||
) | [virtual, inherited] |
Reimplemented in BESDefineCommand, and BESSetCommand.
Definition at line 39 of file BESCommand.cc.
References BESTokenizer::get_next_token().
Referenced by BESShowCommand::parse_request(), parse_request(), BESDeleteCommand::parse_request(), and BESCatalogCommand::parse_request().
BESResponseHandler * BESGetCommand::parse_request | ( | BESTokenizer & | tokenizer, | |
BESDataHandlerInterface & | dhi | |||
) | [virtual] |
knows how to parse a get request
This class knows how to parse a get request, building a sub response handler that actually knows how to build the requested response object, such as das, dds, data, ddx, etc...
A get request looks like:
get <response_type> for <def_name> [return as <ret_name>;
where response_type is the type of response being requested, for example das, dds, dods. where def_name is the name of the definition that has already been created, like a view into the data where ret_name is the method of transmitting the response. This is optional.
This parse method creates the sub response handler, retrieves the definition information and finds the return object if one is specified.
tokenizer | holds on to the list of tokens to be parsed | |
dhi | structure that holds request and response information |
BESSyntaxUserError | if there is a problem parsing the request |
Implements BESCommand.
Definition at line 67 of file BESGetCommand.cc.
References BESCommand::_cmd, BESDataHandlerInterface::action, AGG_CMD, AGG_HANDLER, BESDataHandlerInterface::containers, BESDataHandlerInterface::data, BESDefine::end_container(), BESCommand::find_command(), BESResponseHandlerList::find_handler(), BESDefine::first_container(), BESDefine::get_agg_cmd(), BESDefine::get_agg_handler(), BESTokenizer::get_next_token(), BESDefinitionStorageList::look_for(), BESTokenizer::parse_error(), BESCommand::parse_options(), BESCommand::parse_request(), BESTokenizer::remove_quotes(), RETURN_CMD, BESCommand::TermCommand, BESDefinitionStorageList::TheList(), and BESResponseHandlerList::TheList().
string BESCommand::_cmd [protected, inherited] |
Definition at line 54 of file BESCommand.h.
Referenced by BESCommand::dump(), BESShowCommand::parse_request(), BESSetCommand::parse_request(), parse_request(), BESDeleteCommand::parse_request(), BESDelDefsCommand::parse_request(), BESDelDefCommand::parse_request(), BESDelContainersCommand::parse_request(), BESDelContainerCommand::parse_request(), BESDefineCommand::parse_request(), and BESCatalogCommand::parse_request().
BESCommand * BESCommand::TermCommand = new BESTermCommand( "term" ) [static, inherited] |
Definition at line 68 of file BESCommand.h.
Referenced by DAPCommandModule::initialize(), BESDefaultCommands::initialize(), BESShowCommand::parse_request(), BESSetCommand::parse_request(), parse_request(), BESDeleteCommand::parse_request(), and BESDefineCommand::parse_request().