CMS 3D CMS Logo

TAMuonChamberMatch.cc
Go to the documentation of this file.
7 #include <sstream>
8 
10  int muonSubdetId = id.subdetId();
11 
12  if (muonSubdetId == 1) { //DT
13  DTChamberId segId(id.rawId());
14  return segId.station();
15  }
16  if (muonSubdetId == 2) { //CSC
17  CSCDetId segId(id.rawId());
18  return segId.station();
19  }
20  if (muonSubdetId == 3) { //RPC
21  RPCDetId segId(id.rawId());
22  return segId.station();
23  }
24  if (muonSubdetId == 4) { //GEM
25  GEMDetId segId(id.rawId());
26  return segId.station();
27  }
28  if (muonSubdetId == 5) { //ME0
29  ME0DetId segId(id.rawId());
30  return segId.station();
31  }
32 
33  return -1;
34 }
35 
37  int muonSubdetId = id.subdetId();
38  std::ostringstream oss;
39 
40  if (muonSubdetId == 1) { //DT
41  DTChamberId segId(id.rawId());
42  oss << "DT chamber (wheel, station, sector): " << segId.wheel() << ", " << segId.station() << ", "
43  << segId.sector();
44  }
45 
46  if (muonSubdetId == 2) { //CSC
47  CSCDetId segId(id.rawId());
48  oss << "CSC chamber (endcap, station, ring, chamber, layer): " << segId.endcap() << ", " << segId.station() << ", "
49  << segId.ring() << ", " << segId.chamber() << ", " << segId.layer();
50  }
51  if (muonSubdetId == 3) { //RPC
52  // RPCDetId segId(id.rawId());
53  oss << "RPC chamber";
54  }
55  if (muonSubdetId == 4) { //GEM
56  // GEMDetId segId(id.rawId());
57  oss << "GEM chamber";
58  }
59  if (muonSubdetId == 5) { //ME0
60  // ME0DetId segId(id.rawId());
61  oss << "ME0 chamber";
62  }
63 
64  return oss.str();
65 }
RPCDetId::station
int station() const
Definition: RPCDetId.h:78
CSCDetId::ring
int ring() const
Definition: CSCDetId.h:68
ME0DetId.h
RPCDetId
Definition: RPCDetId.h:16
TAMuonChamberMatch::station
int station() const
Definition: TAMuonChamberMatch.cc:9
TAMuonChamberMatch::info
std::string info() const
Definition: TAMuonChamberMatch.cc:36
CSCDetId.h
CSCDetId::layer
int layer() const
Definition: CSCDetId.h:56
DTChamberId.h
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
RPCDetId.h
GEMDetId
Definition: GEMDetId.h:17
CSCDetId
Definition: CSCDetId.h:26
ME0DetId::station
int station() const
Definition: ME0DetId.h:58
CSCDetId::chamber
int chamber() const
Definition: CSCDetId.h:62
ME0DetId
Definition: ME0DetId.h:16
DTChamberId::sector
int sector() const
Definition: DTChamberId.h:49
GEMDetId.h
TAMuonChamberMatch.h
CSCDetId::endcap
int endcap() const
Definition: CSCDetId.h:85
GEMDetId::station
constexpr int station() const
Definition: GEMDetId.h:173
DTChamberId
Definition: DTChamberId.h:14
CSCDetId::station
int station() const
Definition: CSCDetId.h:79
DTChamberId::wheel
int wheel() const
Return the wheel number.
Definition: DTChamberId.h:39
DTChamberId::station
int station() const
Return the station number.
Definition: DTChamberId.h:42