bes  Updated for version 3.17.4
BESXMLCommand Class Referenceabstract
Inheritance diagram for BESXMLCommand:
Inheritance graph

Public Member Functions

virtual void dump (ostream &strm) const
 dumps information about this object More...
 
virtual BESDataHandlerInterfaceget_dhi ()
 Return the current BESDataHandlerInterface. More...
 
virtual bool has_response ()=0
 Has a response handler been created given the request document? More...
 
virtual void parse_request (xmlNode *node)=0
 Parse the XML request document begining at the given node. More...
 
virtual void prep_request ()
 Prepare any information needed to execute the request of this command.
 

Static Public Member Functions

static void add_command (const string &cmd_str, p_xmlcmd_builder cmd)
 Add a command to the possible commands allowed by this BES. More...
 
static bool del_command (const string &cmd_str)
 Deletes the command called cmd_str from the list of possible commands. More...
 
static p_xmlcmd_builder find_command (const string &cmd_str)
 Find the BESXMLCommand creation function with the given name. More...
 

Protected Member Functions

 BESXMLCommand (const BESDataHandlerInterface &base_dhi)
 Creates a BESXMLCommand document given a base data handler interface object. More...
 
virtual void set_response ()
 The request has been parsed, use the command action name to set the response handler.
 

Protected Attributes

BESDataHandlerInterface _dhi
 
string _str_cmd
 

Detailed Description

Definition at line 51 of file BESXMLCommand.h.

Constructor & Destructor Documentation

◆ BESXMLCommand()

BESXMLCommand::BESXMLCommand ( const BESDataHandlerInterface base_dhi)
protected

Since there can be multiple commands within a single BES request document, there can be multiple data handler interface objects created. Use the one passed as the base interface handler object

Definition at line 48 of file BESXMLCommand.cc.

References BESDataHandlerInterface::make_copy().

Member Function Documentation

◆ add_command()

void BESXMLCommand::add_command ( const string &  cmd_str,
p_xmlcmd_builder  cmd 
)
static

This adds a function to parse a specific BES command within the BES request document using the given name. If a command element is found with the name cmd_str, then the XMLCommand object is created using the passed cmd object.

Parameters
cmd_strThe name of the command
cmdThe function to call to create the BESXMLCommand object

Definition at line 84 of file BESXMLCommand.cc.

◆ del_command()

bool BESXMLCommand::del_command ( const string &  cmd_str)
static
Parameters
cmd_strThe name of the command to remove from the list

Definition at line 94 of file BESXMLCommand.cc.

◆ dump()

void BESXMLCommand::dump ( ostream &  strm) const
virtual

◆ find_command()

p_xmlcmd_builder BESXMLCommand::find_command ( const string &  cmd_str)
static
Parameters
cmd_strThe name of the command creation function to find

Definition at line 109 of file BESXMLCommand.cc.

◆ get_dhi()

virtual BESDataHandlerInterface& BESXMLCommand::get_dhi ( )
inlinevirtual

Since there can be multiple commands within a single request document, different interface objects can be created. This returns the current interface object

Returns
The current BESDataHandlerInterface object

Reimplemented in BESXMLGetCommand.

Definition at line 91 of file BESXMLCommand.h.

References add_command(), del_command(), dump(), and find_command().

◆ has_response()

◆ parse_request()


The documentation for this class was generated from the following files: