CMS 3D CMS Logo

GEMPadDigiCluster.h
Go to the documentation of this file.
1 #ifndef DataFormats_GEMDigi_GEMPadDigiCluster_h
2 #define DataFormats_GEMDigi_GEMPadDigiCluster_h
3 
14 
15 #include <cstdint>
16 #include <iosfwd>
17 #include <vector>
18 
20 public:
21  enum InValid { GE11InValid = 255, GE21InValid = 511 };
22  // Newer GE2/1 geometries will have 16 eta partitions
23  // instead of the usual 8.
24  enum NumberPartitions { ME0 = 8, GE11 = 8, GE21 = 8, GE21SplitStrip = 16 };
25 
26  explicit GEMPadDigiCluster(std::vector<uint16_t> pads,
27  int16_t bx,
29  unsigned nPart = NumberPartitions::GE11);
31 
32  bool operator==(const GEMPadDigiCluster& digi) const;
33  bool operator!=(const GEMPadDigiCluster& digi) const;
34  bool operator<(const GEMPadDigiCluster& digi) const;
35  // only depends on the "InValid" enum so it also
36  // works on unpacked data
37  bool isValid() const;
38 
39  const std::vector<uint16_t>& pads() const { return v_; }
40  int bx() const { return bx_; }
42 
43  unsigned nPartitions() const { return part_; }
44  void print() const;
45 
46 private:
47  std::vector<uint16_t> v_;
48  int32_t bx_;
50  // number of eta partitions
51  unsigned part_;
52 };
53 
54 std::ostream& operator<<(std::ostream& o, const GEMPadDigiCluster& digi);
55 
56 #endif
GEMPadDigiCluster::GE21InValid
Definition: GEMPadDigiCluster.h:21
GEMPadDigiCluster
Definition: GEMPadDigiCluster.h:19
operator<<
std::ostream & operator<<(std::ostream &o, const GEMPadDigiCluster &digi)
Definition: GEMPadDigiCluster.cc:43
GEMPadDigiCluster::pads
const std::vector< uint16_t > & pads() const
Definition: GEMPadDigiCluster.h:39
GEMPadDigiCluster::ME0
Definition: GEMPadDigiCluster.h:24
GEMPadDigiCluster::GEMPadDigiCluster
GEMPadDigiCluster()
Definition: GEMPadDigiCluster.cc:10
GEMPadDigiCluster::bx
int bx() const
Definition: GEMPadDigiCluster.h:40
GEMPadDigiCluster::operator==
bool operator==(const GEMPadDigiCluster &digi) const
Definition: GEMPadDigiCluster.cc:14
EcalTangentSkim_cfg.o
o
Definition: EcalTangentSkim_cfg.py:42
GEMPadDigiCluster::GE21
Definition: GEMPadDigiCluster.h:24
GEMSubDetId.h
GEMPadDigiCluster::isValid
bool isValid() const
Definition: GEMPadDigiCluster.cc:31
GEMPadDigiCluster::print
void print() const
Definition: GEMPadDigiCluster.cc:51
nPart
TString nPart(Int_t part, TString string, TString delimit=";", Bool_t removerest=true)
GEMPadDigiCluster::GE11InValid
Definition: GEMPadDigiCluster.h:21
GEMSubDetId::Station
Station
Definition: GEMSubDetId.h:12
GEMPadDigiCluster::bx_
int32_t bx_
Definition: GEMPadDigiCluster.h:48
GEMPadDigiCluster::operator<
bool operator<(const GEMPadDigiCluster &digi) const
Precedence operator.
Definition: GEMPadDigiCluster.cc:24
GEMPadDigiCluster::NumberPartitions
NumberPartitions
Definition: GEMPadDigiCluster.h:24
GEMPadDigiCluster::nPartitions
unsigned nPartitions() const
Definition: GEMPadDigiCluster.h:43
GEMPadDigiCluster::part_
unsigned part_
Definition: GEMPadDigiCluster.h:51
GEMPadDigiCluster::station_
GEMSubDetId::Station station_
Definition: GEMPadDigiCluster.h:49
GEMPadDigiCluster::v_
std::vector< uint16_t > v_
Definition: GEMPadDigiCluster.h:47
GEMPadDigiCluster::GE21SplitStrip
Definition: GEMPadDigiCluster.h:24
GEMSubDetId::Station::GE11
GEMPadDigiCluster::InValid
InValid
Definition: GEMPadDigiCluster.h:21
GEMPadDigiCluster::GE11
Definition: GEMPadDigiCluster.h:24
GEMPadDigiCluster::station
GEMSubDetId::Station station() const
Definition: GEMPadDigiCluster.h:41
GEMPadDigiCluster::operator!=
bool operator!=(const GEMPadDigiCluster &digi) const
Definition: GEMPadDigiCluster.cc:19