CMS 3D CMS Logo

AHCalDetId.h
Go to the documentation of this file.
1 #ifndef SimG4CMS_HGCalTestBeam_AHCALDETID_H
2 #define SimG4CMS_HGCalTestBeam_AHCALDETID_H 1
3 
4 #include <iosfwd>
8 
13 class AHCalDetId : public DetId {
14 public:
16  AHCalDetId();
18  AHCalDetId(uint32_t rawid);
20  AHCalDetId(int row, int col, int depth);
22  AHCalDetId(const DetId& id);
24  AHCalDetId& operator=(const DetId& id) {
25  id_ = id.rawId();
26  return *this;
27  }
28 
30  HcalSubdetector subdet() const { return HcalOther; }
32  int zside() const { return 1; }
34  int irow() const;
37  int icol() const;
38  int icolAbs() const { return (id_ & HcalDetId::kHcalPhiMask1); }
40  int depth() const;
41 
42  static const AHCalDetId Undefined;
43 
44 private:
45  static constexpr int kMaxRowCol = 16;
46  static constexpr uint32_t kHcalDepthMask = 0x3F;
47 };
48 
49 std::ostream& operator<<(std::ostream&, const AHCalDetId& id);
50 
51 #endif
int icolAbs() const
Definition: AHCalDetId.h:38
static uint32_t kHcalEtaOffset1
Definition: HcalDetId.h:16
int irow() const
get the row number
Definition: AHCalDetId.cc:29
HcalSubdetector subdet() const
get the subdetector
Definition: AHCalDetId.h:30
int depth() const
get the layer number
Definition: AHCalDetId.cc:43
std::ostream & operator<<(std::ostream &, const AHCalDetId &id)
Definition: AHCalDetId.cc:45
int icol() const
get the column number
Definition: AHCalDetId.cc:36
AHCalDetId & operator=(const DetId &id)
Definition: AHCalDetId.h:24
static uint32_t kHcalPhiMask1
Definition: HcalDetId.h:14
HcalSubdetector
Definition: HcalAssistant.h:31
static uint32_t kHcalEtaMask1
Definition: HcalDetId.h:18
static uint32_t kHcalDepthMask
Definition: AHCalDetId.h:46
Definition: DetId.h:17
static const AHCalDetId Undefined
Definition: AHCalDetId.h:42
static int kMaxRowCol
Definition: AHCalDetId.h:45
uint32_t id_
Definition: DetId.h:69
int irowAbs() const
Definition: AHCalDetId.h:35
col
Definition: cuy.py:1010
int zside() const
get the z-side of the cell (1/-1)
Definition: AHCalDetId.h:32
#define constexpr