27 #ifndef NIDAS_CORE_ENGINEINTF_H
28 #define NIDAS_CORE_ENGINEINTF_H
32 #include <xmlrpcpp/XmlRpcException.h>
36 namespace nidas {
namespace core {
70 DSMAction(XmlRpc::XmlRpcServer* s) : XmlRpc::XmlRpcServerMethod(
"DSMAction", s) {}
71 void execute(XmlRpc::XmlRpcValue& params, XmlRpc::XmlRpcValue& result)
throw();
72 std::string
help() {
return std::string(
"parameter \"action\" should be \"start\", \"stop\", \"restart\", \"quit\", \"reboot\" or \"shutdown\""); }
86 void execute(XmlRpc::XmlRpcValue& params, XmlRpc::XmlRpcValue& result)
throw();
88 std::string
help() {
return std::string(
"parameter \"device\" should match a device name for a DSMSensor that has registered itself with DSMEngineIntf"); }
DSMAction _dsmAction
Definition: DSMEngineIntf.h:100
SensorAction _sensorAction
Definition: DSMEngineIntf.h:101
Invoke an executeXmlRpc() method on a DSMSensor.
Definition: DSMEngineIntf.h:82
DSMAction(XmlRpc::XmlRpcServer *s)
Definition: DSMEngineIntf.h:70
void execute(XmlRpc::XmlRpcValue ¶ms, XmlRpc::XmlRpcValue &result)
Definition: DSMEngineIntf.cc:76
void registerSensor(const std::string &devname, DSMSensor *sensor)
Definition: DSMEngineIntf.h:90
std::string help()
Definition: DSMEngineIntf.h:88
void execute(XmlRpc::XmlRpcValue ¶ms, XmlRpc::XmlRpcValue &result)
Definition: DSMEngineIntf.cc:52
Definition: Exception.h:35
void registerSensor(const std::string &devname, DSMSensor *sensor)
Register a sensor to have its executeXmlRpc() method called when a "SensorAction" XmlRpc request come...
Definition: DSMEngineIntf.h:56
DSMSensor provides the basic support for reading, processing and distributing samples from a sensor a...
Definition: DSMSensor.h:87
std::map< std::string, DSMSensor * > _nameToSensor
Definition: DSMEngineIntf.h:96
A thread that provides XML-based Remote Procedure Calls to web interfaces.
Definition: XmlRpcThread.h:39
int run()
The method which will run in its own thread.
Definition: DSMEngineIntf.cc:98
std::string help()
Definition: DSMEngineIntf.h:72
DSMEngineIntf & operator=(const DSMEngineIntf &)
Assignment not needed.
SensorAction(XmlRpc::XmlRpcServer *s)
Definition: DSMEngineIntf.h:85
XmlRpc::XmlRpcServer * _xmlrpc_server
Definition: DSMEngineIntf.h:99
A thread that provides XML-based Remote Procedure Calls to web interfaces from the DSMEngine...
Definition: DSMEngineIntf.h:44
DSMEngineIntf()
Definition: DSMEngineIntf.cc:44
Send a command to a DSMEngine.
Definition: DSMEngineIntf.h:67