SStationListSQLManager.h
Go to the documentation of this file.
1 #ifndef _sdet_SStationListSQLManager_h_
2 #define _sdet_SStationListSQLManager_h_
3 
4 #include <det/VSQLManager_MySQL.h>
5 #include <sdet/SStationListManager.h>
6 
7 
8 namespace sdet {
9 
29 
30  public:
32 
33  virtual void Init(const std::string& configLink);
34 
37  VMANAGER_GETDATA_CALL(GetStationListData, std::string)
38  VMANAGER_GETDATA_CALL(GetStationListData, std::vector<int>)
39  VMANAGER_GETDATA_CALL(GetStationListData, std::vector<std::vector<int> >)
40 
41  //
42 
43  //VMANAGER_GETDATA_NOTFOUND(unsigned long long int)
44  VMANAGER_GETDATA_NOTFOUND(std::vector<bool>)
45  VMANAGER_GETDATA_NOTFOUND(std::list<int>)
46  VMANAGER_GETDATA_NOTFOUND(std::list<std::pair<int, int> >)
47  VMANAGER_GETDATA_NOTFOUND(std::vector<double>)
48  VMANAGER_GETDATA_NOTFOUND(std::vector<std::string>)
49  VMANAGER_GETDATA_NOTFOUND(std::list<double>)
50  VMANAGER_GETDATA_NOTFOUND(std::list<std::string>)
51  VMANAGER_GETDATA_NOTFOUND(std::map<int, utl::TabulatedFunction>)
52  VMANAGER_GETDATA_NOTFOUND(std::map<std::string, double>)
53  VMANAGER_GETDATA_NOTFOUND(utl::TabulatedFunction)
54  VMANAGER_GETDATA_NOTFOUND(utl::TabulatedFunctionComplexLgAmpPhase)
55 
57  { return fStationManager; }
58 
59  private:
60  template<typename T>
61  Status
62  GetStationListData(T& returnData,
63  const std::string& componentProperty,
64  const std::string& componentName,
65  const IndexMap& componentIndex)
66  const
67  {
68  if (componentName != "stationList")
69  return eNotFound;
70  return fStationManager.GetData(returnData, componentProperty,
71  componentIndex);
72  }
73 
75 
76  };
77 
78 }
79 
80 
81 #endif
virtual void Init(const std::string &configLink)
Manager Initialization. configLink is the CentralConfig hook for the configuration file...
Status const
Fetch first item from first row and optionally free query result.
Manager for SD description in SQL station lists.
#define VMANAGER_GETDATA_CALL(_GetData_, _T_...)
Definition: VManager.h:59
Interface for detector managers that use MySQL.
det::VManager::Status GetData(T &returnData, const std::string &componentProperty, const det::VManager::IndexMap &componentIndex) const
Common implementation of the station list manager.
std::map< std::string, std::string > IndexMap
Definition: VManager.h:133
Status GetStationListData(T &returnData, const std::string &componentProperty, const std::string &componentName, const IndexMap &componentIndex) const
const SStationListManager & GetStationListManager() const
#define VMANAGER_GETDATA_NOTFOUND(_T_...)
Definition: VManager.h:41
Status
Specifies success or (eventually) various possible failure modes.
Definition: VManager.h:127

, generated on Tue Sep 26 2023.