CMS 3D CMS Logo

TotemT2ScintNumberingScheme.h
Go to the documentation of this file.
1 #ifndef Forward_TotemT2ScintNumberingScheme_h
2 #define Forward_TotemT2ScintNumberingScheme_h 1
3 
4 #include <cstdint>
5 
7 public:
8  static constexpr uint32_t kTotemT2PhiMask = 0xF;
9  static constexpr uint32_t kTotemT2LayerOffset = 4;
10  static constexpr uint32_t kTotemT2LayerMask = 0x7;
11  static constexpr uint32_t kTotemT2ZsideMask = 0x80;
12 
14 
15  static uint32_t packID(const int& zside, const int& layer, const int& iphi);
16  static int zside(const uint32_t& id) { return (id & kTotemT2ZsideMask) ? (1) : (-1); }
17  static int layer(const uint32_t& id) { return ((id >> kTotemT2LayerOffset) & kTotemT2LayerMask); }
18  static int iphi(const uint32_t& id) { return (id & kTotemT2PhiMask); }
19 };
20 
21 #endif
static constexpr uint32_t kTotemT2ZsideMask
static uint32_t packID(const int &zside, const int &layer, const int &iphi)
static constexpr uint32_t kTotemT2LayerOffset
static int iphi(const uint32_t &id)
static int zside(const uint32_t &id)
static int layer(const uint32_t &id)
static constexpr uint32_t kTotemT2LayerMask
static constexpr uint32_t kTotemT2PhiMask