CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
L1GtTechnicalTrigger.cc
Go to the documentation of this file.
1 
17 // this class header
19 
20 // system include files
21 #include <iomanip>
22 
23 // user include files
25 
26 // constructors
28  m_gtTechnicalTriggerName(""),
29  m_gtTechnicalTriggerBitNumber(0),
30  m_bxInEvent(0), m_gtTechnicalTriggerResult(false)
31 {
32 
33  // empty
34 
35 }
36 
38  const unsigned int ttBitNumber, const int ttBxInEvent,
39  const bool ttResult) :
40  m_gtTechnicalTriggerName(ttName),
41  m_gtTechnicalTriggerBitNumber(ttBitNumber),
42  m_bxInEvent(ttBxInEvent), m_gtTechnicalTriggerResult(ttResult)
43 
44 {
45 
46  // empty
47 
48 }
49 
50 // copy constructor
52 {
53 
56  m_bxInEvent = result.m_bxInEvent;
58 }
59 
60 // destructor
62 {
63 
64  // empty now
65 
66 }
67 
68 // assignment operator
71 {
72 
73  if ( this != &result ) {
74 
77  m_bxInEvent = result.m_bxInEvent;
79 
80  }
81 
82  return *this;
83 
84 }
85 
86 // equal operator
88  const L1GtTechnicalTrigger& result) const
89 {
90 
92  return false;
93  }
94 
96  return false;
97  }
98 
99  if (m_bxInEvent != result.m_bxInEvent) {
100  return false;
101  }
102 
104  return false;
105  }
106 
107  // all members identical
108  return true;
109 
110 }
111 
112 // unequal operator
114  const L1GtTechnicalTrigger& result) const
115 {
116 
117  return !( result == *this);
118 
119 }
120 // methods
121 
122 // set technical trigger name, bit number and result
123 
124 void L1GtTechnicalTrigger::setGtTechnicalTriggerName(const std::string& ttName)
125 {
126 
127  m_gtTechnicalTriggerName = ttName;
128 
129 }
130 
131 // set decision word
133  const unsigned int ttBitNumber)
134 {
135 
136  m_gtTechnicalTriggerBitNumber = ttBitNumber;
137 
138 }
139 
140 void L1GtTechnicalTrigger::setBxInEvent(const int bxInEventValue)
141 {
142 
143  m_bxInEvent = bxInEventValue;
144 
145 }
146 
148 {
149 
150  m_gtTechnicalTriggerResult = ttResult;
151 
152 }
153 
154 // pretty print the content of a L1GtTechnicalTrigger
155 void L1GtTechnicalTrigger::print(std::ostream& myCout) const
156 {
157 
158  myCout << std::endl;
159  myCout << std::endl;
160  myCout << "\nTechnical trigger name: " << m_gtTechnicalTriggerName << std::endl;
161  myCout << " bit number" << m_gtTechnicalTriggerBitNumber << std::endl;
162  myCout << " bxInEvent" << m_bxInEvent << std::endl;
163  myCout << " result" << m_gtTechnicalTriggerResult << std::endl;
164 
166 }
167 
168 // output stream operator
169 std::ostream& operator<<(std::ostream& streamRec,
171 {
172  result.print(streamRec);
173  return streamRec;
174 
175 }
void setGtTechnicalTriggerResult(const bool ttResult)
unsigned int m_gtTechnicalTriggerBitNumber
void setGtTechnicalTriggerName(const std::string &ttName)
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Definition: ALILine.cc:187
virtual ~L1GtTechnicalTrigger()
destructor
bool operator!=(const L1GtTechnicalTrigger &) const
unequal operator
tuple result
Definition: query.py:137
bool operator==(const L1GtTechnicalTrigger &) const
equal operator
L1GtTechnicalTrigger()
constructors
void setBxInEvent(const int bxInEventValue)
void print(std::ostream &myCout) const
pretty print the content of a L1GtTechnicalTrigger
void setGtTechnicalTriggerBitNumber(const unsigned int ttBitNumber)
std::string m_gtTechnicalTriggerName
technical trigger name, bit number, bunch cross in the GT event record and result ...
L1GtTechnicalTrigger & operator=(const L1GtTechnicalTrigger &)
assignment operator