1 #ifndef EUDAQ_INCLUDED_CommandReceiver
2 #define EUDAQ_INCLUDED_CommandReceiver
4 #include "eudaq/ConnectionState.hh"
5 #include "eudaq/Platform.hh"
16 class TransportClient;
23 const std::string &runcontrol,
bool startthread =
true);
24 void SetConnectionState(ConnectionState::State state = ConnectionState::STATE_UNCONF,
const std::string &info =
"");
26 int GetConnectionState() {
return m_connectionstate.GetState();}
30 virtual void OnInitialise(
const Configuration ¶m) { SetConnectionState(eudaq::ConnectionState::STATE_UNCONF);}
32 virtual void OnPrepareRun(
unsigned ) {}
33 virtual void OnStartRun(
unsigned ) { SetConnectionState(eudaq::ConnectionState::STATE_CONF);}
34 virtual void OnStopRun() {}
35 virtual void OnTerminate() {}
36 virtual void OnReset() {}
37 virtual void OnStatus() {}
38 virtual void OnData(
const std::string & ) {}
39 virtual void OnLog(
const std::string & );
40 virtual void OnServer() {}
41 virtual void OnGetRun() {}
42 virtual void OnIdle();
43 virtual void OnClear();
44 virtual void OnUnrecognised(
const std::string & ,
45 const std::string & ) {}
47 void Process(
int timeout);
57 std::string m_type, m_name;
59 std::unique_ptr<std::thread> m_thread;
64 #endif // EUDAQ_INCLUDED_CommandReceiver
Definition: TransportBase.hh:80
Definition: CommandReceiver.hh:20
Definition: Configuration.hh:12
Definition: ConnectionState.hh:15
Definition: TransportClient.hh:9