CMS 3D CMS Logo

L1GtCastorTemplate.cc
Go to the documentation of this file.
1 
21 // this class header
23 
24 // system include files
25 
26 #include <iostream>
27 #include <iomanip>
28 
29 // user include files
30 
31 // base class
32 
35 
36 // forward declarations
37 
38 // constructors
42 }
43 
47 }
48 
50  : L1GtCondition(cName, CondEnergySum, cType) {
53 
54  // actually no objects are sent by CASTOR, only the result of the condition
55  int nObjects = nrObjects();
56 
57  if (nObjects > 0) {
58  m_objectType.reserve(nObjects);
59  }
60 }
61 
62 // copy constructor
64 
65 // destructor
67  // empty now
68 }
69 
70 // assign operator
72  copy(cp);
73  return *this;
74 }
75 
76 void L1GtCastorTemplate::print(std::ostream& myCout) const {
77  myCout << "\n L1GtCastorTemplate print..." << std::endl;
78 
79  L1GtCondition::print(myCout);
80 
81  // reset to decimal output
82  myCout << std::dec << std::endl;
83 }
84 
86  m_condName = cp.condName();
87  m_condCategory = cp.condCategory();
88  m_condType = cp.condType();
89  m_objectType = cp.objectType();
90  m_condGEq = cp.condGEq();
91  m_condChipNr = cp.condChipNr();
92 }
93 
94 // output stream operator
95 std::ostream& operator<<(std::ostream& os, const L1GtCastorTemplate& result) {
96  result.print(os);
97  return os;
98 }
L1GtConditionType
~L1GtCastorTemplate() override
std::vector< L1GtObject > m_objectType
the trigger object type(s)
L1GtConditionType m_condType
the type of the condition (1s, etc)
void print(std::ostream &myCout) const override
print the condition
L1GtConditionCategory m_condCategory
the category of the condition
void copy(const L1GtCastorTemplate &cp)
copy function for copy constructor and operator=
std::string m_condName
the name of the condition
std::ostream & operator<<(std::ostream &os, const L1GtCastorTemplate &result)
L1GtCastorTemplate & operator=(const L1GtCastorTemplate &)
bool m_condGEq
the operator used for the condition (>=, =): true for >=
const int nrObjects() const
get number of trigger objects
int m_condChipNr
condition is located on condition chip m_condChipNr
virtual void print(std::ostream &myCout) const
print condition