otsdaq_demo  v2_05_02_indev
SlowControlsInterfaceTemplate.h
1 #ifndef _ots_SlowControlsInterfaceTemplate_h
2 #define _ots_SlowControlsInterfaceTemplate_h
3 
4 #include <array>
5 #include <string>
6 
7 #include "otsdaq/SlowControlsCore/SlowControlsVInterface.h"
8 
9 namespace ots
10 {
11 // clang-format off
12 class SlowControlsInterfaceTemplate : public SlowControlsVInterface
13 {
14  public:
15  SlowControlsInterfaceTemplate(const std::string& pluginType,
16  const std::string& interfaceUID,
17  const ConfigurationTree& theXDAQContextConfigTree,
18  const std::string& controlsConfigurationPath);
20 
21  void initialize() override;
22  void destroy();
23 
24  std::vector<std::string /*Name*/> getChannelList (void) override;
25  std::string getList (const std::string& format) override;
26  void subscribe (const std::string& Name) override;
27  void subscribeJSON (const std::string& List) override;
28  void unsubscribe (const std::string& Name) override;
29  std::array<std::string, 4> getCurrentValue (const std::string& Name) override;
30  std::array<std::string, 9> getSettings (const std::string& Name) override;
31  std::vector<std::vector<std::string>> getChannelHistory (const std::string& Name) override;
32 
33  std::vector<std::vector<std::string>> getLastAlarms (const std::string& pvName) override;
34  std::vector<std::vector<std::string>> getAlarmsLog (const std::string& pvName) override;
35  std::vector<std::vector<std::string>> checkAlarmNotifications (void) override;
36 
37  virtual bool running (void) override; //This is a workloop/thread, by default do nothing and end thread during running (Note: return true would repeat call)
38 
39 };
40 // clang-format on
41 }
42 
43 #endif