CMS 3D CMS Logo

GEMDigi.cc
Go to the documentation of this file.
1 
9 #include <iostream>
10 
11 GEMDigi::GEMDigi (int strip, int bx) :
12  strip_(strip),
13  bx_(bx)
14 {}
15 
17  strip_(0),
18  bx_(0)
19 {}
20 
21 
22 // Comparison
23 bool GEMDigi::operator == (const GEMDigi& digi) const
24 {
25  return strip_ == digi.strip() and bx_ == digi.bx();
26 }
27 
28 
29 // Comparison
30 bool GEMDigi::operator != (const GEMDigi& digi) const
31 {
32  return strip_ != digi.strip() or bx_ != digi.bx();
33 }
34 
35 
37 bool GEMDigi::operator<(const GEMDigi& digi) const
38 {
39  if(digi.bx() == bx_)
40  return digi.strip() < strip_;
41  else
42  return digi.bx() < bx_;
43 }
44 
45 
46 std::ostream & operator<<(std::ostream & o, const GEMDigi& digi)
47 {
48  return o << " " << digi.strip() << " " << digi.bx();
49 }
50 
51 
52 void GEMDigi::print() const
53 {
54  std::cout << "Strip " << strip() << " bx " << bx() <<std::endl;
55 }
56 
std::ostream & operator<<(std::ostream &o, const GEMDigi &digi)
Definition: GEMDigi.cc:46
void print() const
Definition: GEMDigi.cc:52
bool operator!=(const GEMDigi &digi) const
Definition: GEMDigi.cc:30
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:37
bool operator==(const GEMDigi &digi) const
Definition: GEMDigi.cc:23
int bx() const
Definition: GEMDigi.h:27
uint16_t strip_
Definition: GEMDigi.h:32
GEMDigi()
Definition: GEMDigi.cc:16
int strip() const
Definition: GEMDigi.h:26
int32_t bx_
Definition: GEMDigi.h:33