41#include "BESRequestHandlerList.h"
44#include "BESResponseHandlerList.h"
45#include "BESResponseNames.h"
46#include "BESXMLCommand.h"
48#include "SampleModule.h"
49#include "SampleRequestHandler.h"
50#include "SampleResponseNames.h"
51#include "SampleSayResponseHandler.h"
52#include "SampleSayXMLCommand.h"
54void SampleModule::initialize(
const string &modname)
56 BESDEBUG(modname,
"Initializing Sample Module " << modname << endl);
58 BESRequestHandlerList::TheList()->add_handler(modname,
new SampleRequestHandler(modname));
60 BESResponseHandlerList::TheList()->add_handler(SAY_RESPONSE, SampleSayResponseHandler::SampleSayResponseBuilder);
66 BESDEBUG(modname,
"Done Initializing Sample Module " << modname << endl);
69void SampleModule::terminate(
const string &modname)
71 BESDEBUG(modname,
"Cleaning Sample module " << modname << endl);
73 BESRequestHandler *rh = BESRequestHandlerList::TheList()->remove_handler(modname);
76 BESResponseHandlerList::TheList()->remove_handler( SAY_RESPONSE);
80 BESDEBUG(modname,
"Done Cleaning Sample module " << modname << endl);
92 strm << BESIndent::LMarg <<
"SampleModule::dump - (" << (
void *)
this <<
")" << endl;
static void Register(const std::string &flagName)
register the specified debug flag
static void del_command(const std::string &cmd_str)
Deletes the command called cmd_str from the list of possible commands.
static void add_command(const std::string &cmd_str, p_xmlcmd_builder cmd)
Add a command to the possible commands allowed by this BES.
virtual void dump(std::ostream &strm) const
dump the contents of this object to the specified ostream