CStationListXMLManager.h
Go to the documentation of this file.
1 #ifndef _cdet_CStationListXMLManager_h_
2 #define _cdet_CStationListXMLManager_h_
3 
4 #include <det/VManager.h>
5 #include <cdet/CStationListManager.h>
6 
7 
8 namespace cdet {
9 
30 
31  public:
33 
34  // overload VManager::Init to trigger XML read-in
35  virtual void Init(const std::string& configLink);
36 
39  VMANAGER_GETDATA_CALL(GetStationListData, std::string)
40  VMANAGER_GETDATA_CALL(GetStationListData, std::vector<int>)
41  VMANAGER_GETDATA_CALL(GetStationListData, std::vector<std::vector<int> >)
42  VMANAGER_GETDATA_CALL(GetStationListData, std::vector<bool>)
43 
44  //
45  //VMANAGER_GETDATA_NOTFOUND(unsigned long long int)
46  VMANAGER_GETDATA_NOTFOUND(std::vector<std::string>)
47  VMANAGER_GETDATA_NOTFOUND(std::list<double>)
48  VMANAGER_GETDATA_NOTFOUND(std::list<std::string>)
49  VMANAGER_GETDATA_NOTFOUND(std::list<int>)
50  VMANAGER_GETDATA_NOTFOUND(std::list<std::pair<int, int> >)
51  VMANAGER_GETDATA_NOTFOUND(std::vector<double>)
52  VMANAGER_GETDATA_NOTFOUND(utl::TabulatedFunction)
53  VMANAGER_GETDATA_NOTFOUND(utl::TabulatedFunctionComplexLgAmpPhase)
54  VMANAGER_GETDATA_NOTFOUND(std::map<std::string, double>)
55  VMANAGER_GETDATA_NOTFOUND(std::map<int, utl::TabulatedFunction>)
56 
58  { return fStationManager; }
59 
60  private:
61  template<typename T>
62  Status
63  GetStationListData(T& returnData,
64  const std::string& componentProperty,
65  const std::string& componentName,
66  const IndexMap& componentIndex)
67  const
68  {
69  // we only match componentProperty
70  if (componentName != "stationList")
71  return eNotFound;
72  return fStationManager.GetData(returnData, componentProperty,
73  componentIndex);
74  }
75 
77 
79 
80  };
81 
82 }
83 
84 
85 #endif
const CStationListManager & GetStationListManager() const
Interface for detector managers.
Definition: VManager.h:115
#define VMANAGER_GETDATA_CALL(_GetData_, _T_...)
Definition: VManager.h:59
det::VManager::Status GetData(T &returnData, const std::string &componentProperty, const det::VManager::IndexMap &componentIndex) const
Common implementation of the station list manager.
virtual void Init(const std::string &configLink)
Manager Initialization. configLink is the CentralConfig hook for the configuration file...
VMANAGER_GETDATA_HANDLE_DENIED CStationListManager fStationManager
#define VMANAGER_GETDATA_HANDLE_DENIED
Definition: VManager.h:75
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
#define VMANAGER_GETDATA_NOTFOUND(_T_...)
Definition: VManager.h:41
Manager for MARTA description in XML station lists.
Status
Specifies success or (eventually) various possible failure modes.
Definition: VManager.h:127

, generated on Tue Sep 26 2023.