otsdaq  v2_04_01
EventBuilderApp.h
1 #ifndef _ots_EventBuilderApp_h_
2 #define _ots_EventBuilderApp_h_
3 
4 #include "otsdaq-core/CoreSupervisors/CoreSupervisorBase.h"
5 //#include "otsdaq-core/SupervisorInfo/AllSupervisorInfo.h"
6 //
7 //#include "otsdaq-core/FiniteStateMachine/RunControlStateMachine.h"
8 //#include "otsdaq-core/SOAPUtilities/SOAPMessenger.h"
9 //#include "otsdaq-core/WorkLoopManager/WorkLoopManager.h"
10 
11 #include "artdaq/Application/EventBuilderApp.hh"
12 //
13 //#pragma GCC diagnostic push
14 //#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
15 //#include <xdaq/Application.h>
16 //#pragma GCC diagnostic pop
17 //#include <xgi/Method.h>
18 //#include "otsdaq-core/Macros/XDAQApplicationMacros.h"
19 //
20 //#include <map>
21 //#include <string>
22 //
23 //#include <memory>
24 
25 namespace ots
26 {
27 // class ConfigurationManager;
28 // class TableGroupKey;
29 
33 // EventBuilderApp
34 // This class provides the otsdaq interface to a single artdaq Event Builder,
36 // public xdaq::Application,
37 // public SOAPMessenger,
38 // public RunControlStateMachine
39 {
40  public:
41  XDAQ_INSTANTIATOR();
42 
43  EventBuilderApp(xdaq::ApplicationStub* s);
44  virtual ~EventBuilderApp(void);
45 
46  void init(void);
47  void destroy(void);
48 
49  // void Default(xgi::Input* in, xgi::Output* out);
50  //
51  // // State Machine requests handlers
52  // void stateMachineXgiHandler(xgi::Input* in, xgi::Output* out);
53  // void stateMachineResultXgiHandler(xgi::Input* in, xgi::Output*
54  // out); xoap::MessageReference stateMachineXoapHandler(xoap::MessageReference
55  // message); xoap::MessageReference
56  // stateMachineResultXoapHandler(xoap::MessageReference message); bool
57  // stateMachineThread(toolbox::task::WorkLoop* workLoop);
58  //
59  // xoap::MessageReference stateMachineStateRequest(xoap::MessageReference message);
60  // xoap::MessageReference stateMachineErrorMessageRequest(
61  // xoap::MessageReference message);
62  //
63  // void stateInitial(toolbox::fsm::FiniteStateMachine& fsm);
64  // void statePaused(toolbox::fsm::FiniteStateMachine& fsm);
65  // void stateRunning(toolbox::fsm::FiniteStateMachine& fsm);
66  // void stateHalted(toolbox::fsm::FiniteStateMachine& fsm);
67  // void stateConfigured(toolbox::fsm::FiniteStateMachine& fsm);
68  // void inError(toolbox::fsm::FiniteStateMachine& fsm);
69  //
70 
71  virtual void transitionConfiguring(toolbox::Event::Reference e) override;
72  virtual void transitionHalting(toolbox::Event::Reference e) override;
73  virtual void transitionInitializing(toolbox::Event::Reference e) override;
74  virtual void transitionPausing(toolbox::Event::Reference e) override;
75  virtual void transitionResuming(toolbox::Event::Reference e) override;
76  virtual void transitionStarting(toolbox::Event::Reference e) override;
77  virtual void transitionStopping(toolbox::Event::Reference e) override;
78  // void enteringError(toolbox::Event::Reference e);
79 
80  private:
81  // WorkLoopManager stateMachineWorkLoopManager_;
82  // toolbox::BSem stateMachineSemaphore_;
83  //
84  // AllSupervisorInfo allSupervisorInfo_;
85  // ConfigurationManager* theConfigurationManager_;
86  // const std::string XDAQContextTableName_;
87  // std::string supervisorConfigurationPath_;
88  // std::string supervisorContextUID_;
89  // std::string supervisorApplicationUID_;
90 
91  std::unique_ptr<artdaq::EventBuilderApp> theARTDAQEventBuilderInterface_;
92 };
93 
94 } // namespace ots
95 
96 #endif