otsdaq  v2_05_02_indev
FEProducerVInterface.h
1 #ifndef _ots_FEProducerVInterface_h_
2 #define _ots_FEProducerVInterface_h_
3 
4 #include "otsdaq/DataManager/DataProducerBase.h"
5 #include "otsdaq/FECore/FEVInterface.h"
6 
7 #include <array>
8 #include <iostream>
9 #include <string>
10 #include <vector>
11 
12 namespace ots
13 {
14 // FEProducerVInterface
15 // This class is a virtual class defining the features of front-end interface plugin
16 // class. The features include configuration hooks, finite state machine handlers,
17 // Front-end Macros for web accessible C++ handlers, slow controls hooks, as well as
18 // universal write and read for Macro Maker compatibility.
20 {
21  public:
22  FEProducerVInterface(const std::string& interfaceUID, const ConfigurationTree& theXDAQContextConfigTree, const std::string& interfaceConfigurationPath);
23 
24  virtual ~FEProducerVInterface(void);
25 
26  virtual void startProcessingData(std::string /*runNumber*/) { __FE_COUT__ << "Do nothing. The FE Manager starts the workloop." << __E__; }
27  virtual void stopProcessingData(void) { __FE_COUT__ << "Do nothing. The FE Manager stops the workloop." << __E__; }
28 
29  virtual void copyToNextBuffer(const std::string& dataToWrite);
30  virtual std::string* getNextBuffer(void);
31  virtual void writeCurrentBuffer(void);
32 
33  protected:
34  std::string* dataP_;
35  std::map<std::string, std::string>* headerP_;
36 };
37 
38 } // namespace ots
39 
40 #endif