CMS 3D CMS Logo

DTPerformance.h
Go to the documentation of this file.
1 #ifndef DTPerformance_H
2 #define DTPerformance_H
3 
12 //----------------------
13 // Base Class Headers --
14 //----------------------
15 
16 //------------------------------------
17 // Collaborating Class Declarations --
18 //------------------------------------
20 
24 
25 //---------------
26 // C++ Headers --
27 //---------------
28 #include <string>
29 #include <vector>
30 #include <utility>
31 
32 template <class Key, class Content>
33 class DTBufferTree;
34 
35 // ---------------------
36 // -- Class Interface --
37 // ---------------------
38 
40 public:
43 
44  int wheelId;
45  int stationId;
46  int sectorId;
47  int slId;
48 
50 };
51 
53 public:
56 
57  float meanT0;
58  float meanTtrig;
59  float meanMtime;
60  float meanNoise;
64 
66 };
67 
69 public:
72  DTPerformance();
73  DTPerformance(DTPerformance const&) = delete;
74  DTPerformance& operator=(DTPerformance const&) = delete;
76 
80 
83  int slPerformance(int wheelId,
85  int stationId,
86  int sectorId,
87  int slId,
88  float& meanT0,
89  float& meanTtrig,
90  float& meanMtime,
91  float& meanNoise,
92  float& meanAfterPulse,
93  float& meanResolution,
94  float& meanEfficiency,
95  DTTimeUnits::type unit) const {
96  return get(wheelId,
97  stationId,
98  sectorId,
99  slId,
100  meanT0,
101  meanTtrig,
102  meanMtime,
103  meanNoise,
104  meanAfterPulse,
105  meanResolution,
106  meanEfficiency,
107  unit);
108  };
110  float& meanT0,
111  float& meanTtrig,
112  float& meanMtime,
113  float& meanNoise,
114  float& meanAfterPulse,
115  float& meanResolution,
116  float& meanEfficiency,
117  DTTimeUnits::type unit) const {
118  return get(id, meanT0, meanTtrig, meanMtime, meanNoise, meanAfterPulse, meanResolution, meanEfficiency, unit);
119  };
120  int get(int wheelId,
121  int stationId,
122  int sectorId,
123  int slId,
124  float& meanT0,
125  float& meanTtrig,
126  float& meanMtime,
127  float& meanNoise,
128  float& meanAfterPulse,
129  float& meanResolution,
130  float& meanEfficiency,
131  DTTimeUnits::type unit) const;
132  int get(const DTSuperLayerId& id,
133  float& meanT0,
134  float& meanTtrig,
135  float& meanMtime,
136  float& meanNoise,
137  float& meanAfterPulse,
138  float& meanResolution,
139  float& meanEfficiency,
140  DTTimeUnits::type unit) const;
141  float unit() const;
142 
144  const std::string& version() const;
145  std::string& version();
146 
148  void clear();
149 
150  int setSLPerformance(int wheelId,
151  int stationId,
152  int sectorId,
153  int slId,
154  float meanT0,
155  float meanTtrig,
156  float meanMtime,
157  float meanNoise,
158  float meanAfterPulse,
159  float meanResolution,
160  float meanEfficiency,
162  return set(wheelId,
163  stationId,
164  sectorId,
165  slId,
166  meanT0,
167  meanTtrig,
168  meanMtime,
169  meanNoise,
170  meanAfterPulse,
171  meanResolution,
172  meanEfficiency,
173  unit);
174  };
176  float meanT0,
177  float meanTtrig,
178  float meanMtime,
179  float meanNoise,
180  float meanAfterPulse,
181  float meanResolution,
182  float meanEfficiency,
184  return set(id, meanT0, meanTtrig, meanMtime, meanNoise, meanAfterPulse, meanResolution, meanEfficiency, unit);
185  };
186  int set(int wheelId,
187  int stationId,
188  int sectorId,
189  int slId,
190  float meanT0,
191  float meanTtrig,
192  float meanMtime,
193  float meanNoise,
194  float meanAfterPulse,
195  float meanResolution,
196  float meanEfficiency,
198  int set(const DTSuperLayerId& id,
199  float meanT0,
200  float meanTtrig,
201  float meanMtime,
202  float meanNoise,
203  float meanAfterPulse,
204  float meanResolution,
205  float meanEfficiency,
207  void setUnit(float unit);
208 
210  typedef std::vector<std::pair<DTPerformanceId, DTPerformanceData> >::const_iterator const_iterator;
211  const_iterator begin() const;
212  const_iterator end() const;
213 
214  void initialize();
215 
216 private:
218  float nsPerCount;
219 
220  std::vector<std::pair<DTPerformanceId, DTPerformanceData> > dataList;
221 
223 
225  std::string mapName() const;
226 
228 };
229 #endif // DTPerformance_H
DTPerformance & operator=(DTPerformance const &)=delete
const std::string & version() const
access version
void setUnit(float unit)
void clear()
reset content
int slPerformance(const DTSuperLayerId &id, float &meanT0, float &meanTtrig, float &meanMtime, float &meanNoise, float &meanAfterPulse, float &meanResolution, float &meanEfficiency, DTTimeUnits::type unit) const
const_iterator end() const
int setSLPerformance(int wheelId, int stationId, int sectorId, int slId, float meanT0, float meanTtrig, float meanMtime, float meanNoise, float meanAfterPulse, float meanResolution, float meanEfficiency, DTTimeUnits::type unit)
#define COND_TRANSIENT
Definition: Serializable.h:63
std::string dataVersion
#define COND_SERIALIZABLE
Definition: Serializable.h:39
DTBufferTree< int, int > * dBuf
const_iterator begin() const
std::string mapName() const
read and store full content
std::vector< std::pair< DTPerformanceId, DTPerformanceData > >::const_iterator const_iterator
Access methods to data.
std::vector< std::pair< DTPerformanceId, DTPerformanceData > > dataList
float unit() const
int slPerformance(int wheelId, int stationId, int sectorId, int slId, float &meanT0, float &meanTtrig, float &meanMtime, float &meanNoise, float &meanAfterPulse, float &meanResolution, float &meanEfficiency, DTTimeUnits::type unit) const
get content
Definition: DTPerformance.h:84
int setSLPerformance(const DTSuperLayerId &id, float meanT0, float meanTtrig, float meanMtime, float meanNoise, float meanAfterPulse, float meanResolution, float meanEfficiency, DTTimeUnits::type unit)