CMS 3D CMS Logo

GEMDigi.cc
Go to the documentation of this file.
2 #include <iostream>
3 
4 GEMDigi::GEMDigi(int strip, int bx) : strip_(strip), bx_(bx) {}
5 
6 GEMDigi::GEMDigi() : strip_(65535), bx_(-99) {}
7 
8 // Comparison
9 bool GEMDigi::operator==(const GEMDigi& digi) const { return strip_ == digi.strip() and bx_ == digi.bx(); }
10 
11 // Comparison
12 bool GEMDigi::operator!=(const GEMDigi& digi) const { return strip_ != digi.strip() or bx_ != digi.bx(); }
13 
15 bool GEMDigi::operator<(const GEMDigi& digi) const {
16  if (digi.bx() == bx_)
17  return digi.strip() < strip_;
18  else
19  return digi.bx() < bx_;
20 }
21 
22 bool GEMDigi::isValid() const { return bx_ != -99 and strip_ != 65535; }
23 
24 std::ostream& operator<<(std::ostream& o, const GEMDigi& digi) {
25  return o << " GEMDigi strip = " << digi.strip() << " bx = " << digi.bx();
26 }
27 
28 void GEMDigi::print() const { std::cout << "Strip " << strip() << " bx " << bx() << std::endl; }
std::ostream & operator<<(std::ostream &o, const GEMDigi &digi)
Definition: GEMDigi.cc:24
void print() const
Definition: GEMDigi.cc:28
bool operator!=(const GEMDigi &digi) const
Definition: GEMDigi.cc:12
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
bool operator<(const GEMDigi &digi) const
Precedence operator.
Definition: GEMDigi.cc:15
bool operator==(const GEMDigi &digi) const
Definition: GEMDigi.cc:9
bool isValid() const
Definition: GEMDigi.cc:22
int bx() const
Definition: GEMDigi.h:27
uint16_t strip_
Definition: GEMDigi.h:32
GEMDigi()
Definition: GEMDigi.cc:6
int strip() const
Definition: GEMDigi.h:26
int16_t bx_
Definition: GEMDigi.h:33