CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DTT0.h
Go to the documentation of this file.
1 #ifndef DTT0_H
2 #define DTT0_H
3 
13 //----------------------
14 // Base Class Headers --
15 //----------------------
16 
17 //------------------------------------
18 // Collaborating Class Declarations --
19 //------------------------------------
21 
24 
25 //---------------
26 // C++ Headers --
27 //---------------
28 #include <string>
29 #include <vector>
30 #include <map>
31 
32 // ---------------------
33 // -- Class Interface --
34 // ---------------------
35 
36 class DTT0Data {
37 public:
38  DTT0Data();
39  ~DTT0Data();
40 
41  uint32_t channelId;
42  float t0mean;
43  float t0rms;
44 
46 };
47 
48 class DTT0 {
49 public:
52  DTT0();
53  DTT0(const std::string& version);
54 
57  ~DTT0();
58 
61  int cellT0(int wheelId,
63  int stationId,
64  int sectorId,
65  int slId,
66  int layerId,
67  int cellId,
68  float& t0mean,
69  float& t0rms,
70  DTTimeUnits::type unit) const {
71  return get(wheelId, stationId, sectorId, slId, layerId, cellId, t0mean, t0rms, unit);
72  };
73  int cellT0(const DTWireId& id, float& t0mean, float& t0rms, DTTimeUnits::type unit) const {
74  return get(id, t0mean, t0rms, unit);
75  };
76  int get(int wheelId,
77  int stationId,
78  int sectorId,
79  int slId,
80  int layerId,
81  int cellId,
82  float& t0mean,
83  float& t0rms,
84  DTTimeUnits::type unit) const;
85  int get(const DTWireId& id, float& t0mean, float& t0rms, DTTimeUnits::type unit) const;
86  float unit() const;
87 
89  const std::string& version() const;
91 
93  void clear();
94 
95  int setCellT0(int wheelId,
96  int stationId,
97  int sectorId,
98  int slId,
99  int layerId,
100  int cellId,
101  float t0mean,
102  float t0rms,
103  DTTimeUnits::type unit) {
104  return set(wheelId, stationId, sectorId, slId, layerId, cellId, t0mean, t0rms, unit);
105  };
106  int setCellT0(const DTWireId& id, float t0mean, float t0rms, DTTimeUnits::type unit) {
107  return set(id, t0mean, t0rms, unit);
108  };
109  int set(int wheelId,
110  int stationId,
111  int sectorId,
112  int slId,
113  int layerId,
114  int cellId,
115  float t0mean,
116  float t0rms,
117  DTTimeUnits::type unit);
118  int set(const DTWireId& id, float t0mean, float t0rms, DTTimeUnits::type unit);
119  void setUnit(float unit);
120 
122  typedef std::vector<DTT0Data>::const_iterator const_iterator;
123  const_iterator begin() const;
124  const_iterator end() const;
125 
126 private:
128  float nsPerCount;
129 
130  std::vector<DTT0Data> dataList;
131 
133 };
134 
135 #endif // DTT0_H
const_iterator begin() const
Definition: DTT0.cc:145
int set(int wheelId, int stationId, int sectorId, int slId, int layerId, int cellId, float t0mean, float t0rms, DTTimeUnits::type unit)
Definition: DTT0.cc:97
int setCellT0(int wheelId, int stationId, int sectorId, int slId, int layerId, int cellId, float t0mean, float t0rms, DTTimeUnits::type unit)
Definition: DTT0.h:95
uint16_t *__restrict__ id
uint32_t channelId
Definition: DTT0.h:41
int setCellT0(const DTWireId &id, float t0mean, float t0rms, DTTimeUnits::type unit)
Definition: DTT0.h:106
DTT0()
Definition: DTT0.cc:31
std::string dataVersion
Definition: DTT0.h:127
std::vector< DTT0Data >::const_iterator const_iterator
Access methods to data.
Definition: DTT0.h:122
Definition: DTT0.h:48
int cellT0(const DTWireId &id, float &t0mean, float &t0rms, DTTimeUnits::type unit) const
Definition: DTT0.h:73
void setUnit(float unit)
Definition: DTT0.cc:143
DTT0Data()
Definition: DTT0.cc:36
std::vector< DTT0Data > dataList
Definition: DTT0.h:130
const_iterator end() const
Definition: DTT0.cc:147
float unit() const
Definition: DTT0.cc:80
~DTT0Data()
Definition: DTT0.cc:43
float nsPerCount
Definition: DTT0.h:128
#define COND_SERIALIZABLE
Definition: Serializable.h:39
int cellT0(int wheelId, int stationId, int sectorId, int slId, int layerId, int cellId, float &t0mean, float &t0rms, DTTimeUnits::type unit) const
get content
Definition: DTT0.h:62
~DTT0()
Definition: DTT0.cc:41
const std::string & version() const
access version
Definition: DTT0.cc:82
void clear()
reset content
Definition: DTT0.cc:86
float t0rms
Definition: DTT0.h:43
float t0mean
Definition: DTT0.h:42
Definition: DTT0.h:36