CMS 3D CMS Logo

DTReadOutMapping.h
Go to the documentation of this file.
1 #ifndef DTReadOutMapping_H
2 #define DTReadOutMapping_H
3 
15 //----------------------
16 // Base Class Headers --
17 //----------------------
18 
19 //------------------------------------
20 // Collaborating Class Declarations --
21 //------------------------------------
23 
27 
28 //---------------
29 // C++ Headers --
30 //---------------
31 #include <vector>
32 #include <string>
33 
35 template <class Key, class Content>
36 class DTBufferTree;
37 
38 // ---------------------
39 // -- Class Interface --
40 // ---------------------
41 
43 public:
46 
47  int dduId;
48  int rosId;
49  int robId;
50  int tdcId;
51  int channelId;
52  int wheelId;
53  int stationId;
54  int sectorId;
55  int slId;
56  int layerId;
57  int cellId;
58 
60 };
61 
63 public:
67  DTReadOutMapping(const std::string& cell_map_version, const std::string& rob_map_version);
68 
72 
73  enum type { plain, compact };
74 
77  int readOutToGeometry(int dduId, int rosId, int robId, int tdcId, int channelId, DTWireId& wireId) const;
79 
80  int readOutToGeometry(int dduId,
81  int rosId,
82  int robId,
83  int tdcId,
84  int channelId,
85  int& wheelId,
86  int& stationId,
87  int& sectorId,
88  int& slId,
89  int& layerId,
90  int& cellId) const;
91 
92  int geometryToReadOut(int wheelId,
93  int stationId,
94  int sectorId,
95  int slId,
96  int layerId,
97  int cellId,
98  int& dduId,
99  int& rosId,
100  int& robId,
101  int& tdcId,
102  int& channelId) const;
103  int geometryToReadOut(const DTWireId& wireId, int& dduId, int& rosId, int& robId, int& tdcId, int& channelId) const;
104 
105  type mapType() const;
106 
108  const std::string& mapCellTdc() const;
109  std::string& mapCellTdc();
110  const std::string& mapRobRos() const;
111  std::string& mapRobRos();
112 
114  void clear();
115 
117  int insertReadOutGeometryLink(int dduId,
118  int rosId,
119  int robId,
120  int tdcId,
121  int channelId,
122  int wheelId,
123  int stationId,
124  int sectorId,
125  int slId,
126  int layerId,
127  int cellId);
128 
130  typedef std::vector<DTReadOutGeometryLink>::const_iterator const_iterator;
131  const_iterator begin() const;
132  const_iterator end() const;
133 
135  const DTReadOutMapping* fullMap() const;
136 
137 private:
138  DTReadOutMapping(DTReadOutMapping const&) = delete;
139  DTReadOutMapping& operator=(DTReadOutMapping const&) = delete;
140 
141  edm::AtomicPtrCache<DTReadOutMappingCache> const& atomicCache() const { return atomicCache_; }
143 
144  static DTReadOutMapping* expandMap(const DTReadOutMapping& compMap);
145 
148 
149  std::vector<DTReadOutGeometryLink> readOutChannelDriftTubeMap;
150 
154 
156  void cacheMap() const;
157 
158  std::string mapNameRG() const;
159  std::string mapNameGR() const;
160 
162 };
163 #endif // DTReadOutMapping_H
std::string robMapVersion
std::vector< DTReadOutGeometryLink >::const_iterator const_iterator
Access methods to the connections.
std::vector< DTReadOutGeometryLink > readOutChannelDriftTubeMap
void clear(CLHEP::HepGenMatrix &m)
Helper function: Reset all elements of a matrix to 0.
Definition: matutil.cc:151
#define end
Definition: vmac.h:39
#define COND_TRANSIENT
Definition: Serializable.h:62
edm::AtomicPtrCache< DTReadOutMappingCache > & atomicCache()
#define COND_SERIALIZABLE
Definition: Serializable.h:38
#define begin
Definition: vmac.h:32
std::string cellMapVersion
edm::AtomicPtrCache< DTReadOutMappingCache > const & atomicCache() const