CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
L1GlobalTriggerObjectMapRecord Class Reference

#include <L1GlobalTriggerObjectMapRecord.h>

Public Member Functions

const CombinationsInCondgetCombinationsInCond (const std::string &algoNameVal, const std::string &condNameVal) const
 
const CombinationsInCondgetCombinationsInCond (const int algoBitNumberVal, const std::string &condNameVal) const
 
bool getConditionResult (const std::string &algoNameVal, const std::string &condNameVal) const
 
bool getConditionResult (const int algoBitNumberVal, const std::string &condNameVal) const
 
const L1GlobalTriggerObjectMapgetObjectMap (const std::string &algoNameVal) const
 return the object map for the algorithm algoNameVal More...
 
const L1GlobalTriggerObjectMapgetObjectMap (const int algoBitNumberVal) const
 return the object map for the algorithm with bit number const int algoBitNumberVal More...
 
const std::vector< L1GlobalTriggerObjectMap > & gtObjectMap () const
 get / set the vector of object maps More...
 
 L1GlobalTriggerObjectMapRecord ()
 constructor(s) More...
 
void setGtObjectMap (const std::vector< L1GlobalTriggerObjectMap > &gtObjectMapValue)
 
void swap (L1GlobalTriggerObjectMapRecord &rh)
 
void swapGtObjectMap (std::vector< L1GlobalTriggerObjectMap > &gtObjectMapValue)
 
 ~L1GlobalTriggerObjectMapRecord ()
 destructor More...
 

Private Attributes

std::vector< L1GlobalTriggerObjectMapm_gtObjectMap
 

Detailed Description

Description: map trigger objects to algorithms and conditions.

Implementation: <TODO: enter implementation details>

Author
: Vasile Mihai Ghete - HEPHY Vienna

Description: see header file.

Implementation: <TODO: enter implementation details>

Author
: Vasile Mihai Ghete - HEPHY Vienna

Description: see header file.

Implementation: <TODO: enter implementation details>

Author
: Vasile Mihai Ghete - HEPHY Vienna
: W. David Dagenhart

Definition at line 29 of file L1GlobalTriggerObjectMapRecord.h.

Constructor & Destructor Documentation

L1GlobalTriggerObjectMapRecord::L1GlobalTriggerObjectMapRecord ( )
inline

constructor(s)

Definition at line 35 of file L1GlobalTriggerObjectMapRecord.h.

35 {}
L1GlobalTriggerObjectMapRecord::~L1GlobalTriggerObjectMapRecord ( )
inline

destructor

Definition at line 38 of file L1GlobalTriggerObjectMapRecord.h.

38 {}

Member Function Documentation

const CombinationsInCond * L1GlobalTriggerObjectMapRecord::getCombinationsInCond ( const std::string &  algoNameVal,
const std::string &  condNameVal 
) const

return all the combinations passing the requirements imposed in condition condNameVal from algorithm with name algoNameVal

Definition at line 84 of file L1GlobalTriggerObjectMapRecord.cc.

References m_gtObjectMap.

Referenced by L1GtAnalyzer::analyzeObjectMap(), and swap().

86 {
87 
88  for (std::vector<L1GlobalTriggerObjectMap>::const_iterator itObj = m_gtObjectMap.begin();
89  itObj != m_gtObjectMap.end(); ++itObj) {
90 
91  if ( itObj->algoName() == algoNameVal ) {
92 
93  return itObj->getCombinationsInCond(condNameVal);
94 
95  }
96  }
97 
98  // no (algoName, condName) found, return zero pointer!
99  edm::LogError("L1GlobalTriggerObjectMapRecord")
100  << " ERROR: The requested (algorithm name, condition name) = ("
101  << algoNameVal << ", " << condNameVal
102  << ") does not exist in the trigger menu."
103  << " Returning zero pointer for getCombinationsInCond."
104  << std::endl;
105 
106  return nullptr;
107 
108 }
std::vector< L1GlobalTriggerObjectMap > m_gtObjectMap
const CombinationsInCond * L1GlobalTriggerObjectMapRecord::getCombinationsInCond ( const int  algoBitNumberVal,
const std::string &  condNameVal 
) const

return all the combinations passing the requirements imposed in condition condNameVal from algorithm with bit number algoBitNumberVal

Definition at line 112 of file L1GlobalTriggerObjectMapRecord.cc.

References m_gtObjectMap.

114 {
115 
116  for (std::vector<L1GlobalTriggerObjectMap>::const_iterator itObj = m_gtObjectMap.begin();
117  itObj != m_gtObjectMap.end(); ++itObj) {
118 
119  if ( itObj->algoBitNumber() == algoBitNumberVal ) {
120  return itObj->getCombinationsInCond(condNameVal);
121  }
122  }
123 
124  // no (algoBitNumber, condName) found, return zero pointer!
125  edm::LogError("L1GlobalTriggerObjectMapRecord")
126  << " ERROR: The requested (algorithm bit number, condition name) = ("
127  << algoBitNumberVal << ", " << condNameVal
128  << ") does not exist in the trigger menu."
129  << " Returning zero pointer for getCombinationsInCond."
130  << std::endl;
131 
132  return nullptr;
133 
134 }
std::vector< L1GlobalTriggerObjectMap > m_gtObjectMap
bool L1GlobalTriggerObjectMapRecord::getConditionResult ( const std::string &  algoNameVal,
const std::string &  condNameVal 
) const

return the result for the condition condNameVal from algorithm with name algoNameVal

Definition at line 138 of file L1GlobalTriggerObjectMapRecord.cc.

References m_gtObjectMap.

Referenced by L1GtAnalyzer::analyzeObjectMap(), and swap().

140 {
141 
142  for (std::vector<L1GlobalTriggerObjectMap>::const_iterator itObj = m_gtObjectMap.begin();
143  itObj != m_gtObjectMap.end(); ++itObj) {
144 
145  if ( itObj->algoName() == algoNameVal ) {
146  return itObj->getConditionResult(condNameVal);
147  }
148  }
149 
150  // no (algoName, condName) found, return false!
151  edm::LogError("L1GlobalTriggerObjectMapRecord")
152  << " ERROR: The requested (algorithm name, condition name) = ("
153  << algoNameVal << ", " << condNameVal
154  << ") does not exist in the trigger menu."
155  << " Returning false for condition result! Unknown result, in fact!"
156  << std::endl;
157 
158  return false;
159 
160 }
std::vector< L1GlobalTriggerObjectMap > m_gtObjectMap
bool L1GlobalTriggerObjectMapRecord::getConditionResult ( const int  algoBitNumberVal,
const std::string &  condNameVal 
) const

return the result for the condition condNameVal from algorithm with bit number algoBitNumberVal

Definition at line 164 of file L1GlobalTriggerObjectMapRecord.cc.

References m_gtObjectMap.

166 {
167 
168  for (std::vector<L1GlobalTriggerObjectMap>::const_iterator itObj = m_gtObjectMap.begin();
169  itObj != m_gtObjectMap.end(); ++itObj) {
170 
171  if ( itObj->algoBitNumber() == algoBitNumberVal ) {
172  return itObj->getConditionResult(condNameVal);
173  }
174  }
175 
176  // no (algoBitNumber, condName) found, return false!
177  edm::LogError("L1GlobalTriggerObjectMapRecord")
178  << " ERROR: The requested (algorithm bit number, condition name) = ("
179  << algoBitNumberVal << ", " << condNameVal
180  << ") does not exist in the trigger menu."
181  << " Returning false for condition result! Unknown result, in fact!"
182  << std::endl;
183 
184  return false;
185 
186 }
std::vector< L1GlobalTriggerObjectMap > m_gtObjectMap
const L1GlobalTriggerObjectMap * L1GlobalTriggerObjectMapRecord::getObjectMap ( const std::string &  algoNameVal) const

return the object map for the algorithm algoNameVal

Definition at line 35 of file L1GlobalTriggerObjectMapRecord.cc.

References m_gtObjectMap.

Referenced by CompareToObjectMapRecord::analyze(), ConvertObjectMapRecord::produce(), HLTLevel1GTSeed::seedsL1TriggerObjectMaps(), and swap().

36  {
37 
38  for (std::vector<L1GlobalTriggerObjectMap>::const_iterator
39  itObj = m_gtObjectMap.begin(); itObj != m_gtObjectMap.end(); ++itObj) {
40 
41  if (itObj->algoName() == algoNameVal) {
42 
43  return &((*itObj));
44  }
45 
46  }
47 
48  // no algoName found, return zero pointer!
49  edm::LogError("L1GlobalTriggerObjectMapRecord")
50  << " ERROR: The requested algorithm name = " << algoNameVal
51  << " does not exist in the trigger menu."
52  << " Returning zero pointer for getObjectMap." << std::endl;
53 
54  return nullptr;
55 
56 }
std::vector< L1GlobalTriggerObjectMap > m_gtObjectMap
const L1GlobalTriggerObjectMap * L1GlobalTriggerObjectMapRecord::getObjectMap ( const int  algoBitNumberVal) const

return the object map for the algorithm with bit number const int algoBitNumberVal

Definition at line 59 of file L1GlobalTriggerObjectMapRecord.cc.

References m_gtObjectMap.

60  {
61 
62  for (std::vector<L1GlobalTriggerObjectMap>::const_iterator
63  itObj = m_gtObjectMap.begin(); itObj != m_gtObjectMap.end(); ++itObj) {
64 
65  if (itObj->algoBitNumber() == algoBitNumberVal) {
66 
67  return &((*itObj));
68  }
69 
70  }
71 
72  // no algoBitNumberVal found, return zero pointer!
73  edm::LogError("L1GlobalTriggerObjectMapRecord")
74  << " ERROR: The requested algorithm with bit number = " << algoBitNumberVal
75  << " does not exist in the trigger menu."
76  << " Returning zero pointer for getObjectMap." << std::endl;
77 
78  return nullptr;
79 
80 }
std::vector< L1GlobalTriggerObjectMap > m_gtObjectMap
const std::vector<L1GlobalTriggerObjectMap>& L1GlobalTriggerObjectMapRecord::gtObjectMap ( ) const
inline
void L1GlobalTriggerObjectMapRecord::setGtObjectMap ( const std::vector< L1GlobalTriggerObjectMap > &  gtObjectMapValue)
inline

Definition at line 78 of file L1GlobalTriggerObjectMapRecord.h.

References m_gtObjectMap.

79  {
80  m_gtObjectMap = gtObjectMapValue;
81  }
std::vector< L1GlobalTriggerObjectMap > m_gtObjectMap
void L1GlobalTriggerObjectMapRecord::swap ( L1GlobalTriggerObjectMapRecord rh)
inline
void L1GlobalTriggerObjectMapRecord::swapGtObjectMap ( std::vector< L1GlobalTriggerObjectMap > &  gtObjectMapValue)
inline

Definition at line 83 of file L1GlobalTriggerObjectMapRecord.h.

References m_gtObjectMap.

Referenced by L1GlobalTriggerGTL::run().

84  {
85  m_gtObjectMap.swap(gtObjectMapValue);
86  }
std::vector< L1GlobalTriggerObjectMap > m_gtObjectMap

Member Data Documentation

std::vector<L1GlobalTriggerObjectMap> L1GlobalTriggerObjectMapRecord::m_gtObjectMap
private