tdaq-develop-2025-02-12
UDPDataStreamerConsumer.h
1 #ifndef _ots_UDPDataStreamerConsumer_h_
2 #define _ots_UDPDataStreamerConsumer_h_
3 
4 #include "otsdaq/Configurable/Configurable.h"
5 #include "otsdaq/DataManager/DataConsumer.h"
6 #include "otsdaq/NetworkUtilities/UDPDataStreamerBase.h"
7 
8 #include <string>
9 
10 namespace ots
11 {
12 class ConfigurationTree;
13 
15  public DataConsumer,
16  public Configurable
17 {
18  public:
19  UDPDataStreamerConsumer(std::string supervisorApplicationUID,
20  std::string bufferUID,
21  std::string processorUID,
22  const ConfigurationTree& theXDAQContextConfigTree,
23  const std::string& configurationPath);
24  virtual ~UDPDataStreamerConsumer(void);
25 
26  protected:
27  bool workLoopThread(toolbox::task::WorkLoop* workLoop);
28 
29  void fastRead(void);
30  void slowRead(void);
31 
33  std::string* dataP_;
34  std::map<std::string, std::string>* headerP_;
36  std::string data_;
37  std::map<std::string, std::string> header_;
38 };
39 
40 } // namespace ots
41 
42 #endif
std::string * dataP_
For fast read.
std::string data_
For slow read.
UDPDataStreamerConsumer(std::string supervisorApplicationUID, std::string bufferUID, std::string processorUID, const ConfigurationTree &theXDAQContextConfigTree, const std::string &configurationPath)