CMS 3D CMS Logo

GEMPadDigi.cc
Go to the documentation of this file.
2 #include <iostream>
3 
4 GEMPadDigi::GEMPadDigi(uint16_t pad, int16_t bx, enum GEMSubDetId::Station station, unsigned nPart)
5  : pad_(pad), bx_(bx), station_(station), part_(nPart) {}
6 
8  : pad_(GE11InValid), bx_(-99), station_(GEMSubDetId::Station::GE11), part_(NumberPartitions::GE11) {}
9 
10 // Comparison
11 bool GEMPadDigi::operator==(const GEMPadDigi& digi) const {
12  return pad_ == digi.pad() and bx_ == digi.bx() and station_ == digi.station();
13 }
14 
15 // Comparison
16 bool GEMPadDigi::operator!=(const GEMPadDigi& digi) const { return pad_ != digi.pad() or bx_ != digi.bx(); }
17 
19 bool GEMPadDigi::operator<(const GEMPadDigi& digi) const {
20  if (digi.bx() == bx_)
21  return digi.pad() < pad_;
22  else
23  return digi.bx() < bx_;
24 }
25 
26 bool GEMPadDigi::isValid() const {
27  uint16_t invalid = GE11InValid;
30  } else if (station_ == GEMSubDetId::Station::GE21) {
32  }
33  return pad_ != invalid;
34 }
35 
36 std::ostream& operator<<(std::ostream& o, const GEMPadDigi& digi) {
37  return o << " GEMPadDigi Pad = " << digi.pad() << " bx = " << digi.bx();
38 }
39 
40 void GEMPadDigi::print() const { std::cout << "Pad " << pad() << " bx " << bx() << std::endl; }
int16_t bx() const
Definition: GEMPadDigi.h:39
std::ostream & operator<<(std::ostream &o, const GEMPadDigi &digi)
Definition: GEMPadDigi.cc:36
GEMSubDetId::Station station() const
Definition: GEMPadDigi.h:40
bool operator==(const GEMPadDigi &digi) const
Definition: GEMPadDigi.cc:11
bool isValid() const
Definition: GEMPadDigi.cc:26
uint16_t pad_
Definition: GEMPadDigi.h:46
GEMSubDetId::Station station_
Definition: GEMPadDigi.h:48
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventID const &, edm::Timestamp const & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
Definition: Activities.doc:12
TString nPart(Int_t part, TString string, TString delimit=";", Bool_t removerest=true)
uint16_t pad() const
Definition: GEMPadDigi.h:38
void print() const
Definition: GEMPadDigi.cc:40
bool operator<(const GEMPadDigi &digi) const
Precedence operator.
Definition: GEMPadDigi.cc:19
bool operator!=(const GEMPadDigi &digi) const
Definition: GEMPadDigi.cc:16
int16_t bx_
Definition: GEMPadDigi.h:47