CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
TriggerExpressionData.h
Go to the documentation of this file.
1 #ifndef HLTrigger_HLTfilters_TriggerExpressionData_h
2 #define HLTrigger_HLTfilters_TriggerExpressionData_h
3 
11 
12 namespace edm {
13  class Event;
14  class EventSetup;
15  class TriggerNames;
16 }
17 
18 class L1GtTriggerMenu;
19 class L1GtTriggerMask;
20 
21 namespace triggerExpression {
22 
23 class Data {
24 public:
25  // default c'tor
26  Data() :
27  // configuration
28  m_hltResultsTag(""),
30  m_l1tResultsTag(""),
32  m_daqPartitions(0x01),
35  m_throw(true),
36  // l1 values and status
37  m_l1tResults(0),
38  m_l1tMenu(0),
39  m_l1tAlgoMask(0),
40  m_l1tTechMask(0),
41  m_l1tCacheID(),
43  // hlt values and status
44  m_hltResults(0),
45  m_hltMenu(0),
46  m_hltCacheID(),
48  // event values
50  { }
51 
52  // explicit c'tor from a ParameterSet
54  // configuration
55  m_hltResultsTag(config.getParameter<edm::InputTag>("hltResults")),
57  m_l1tResultsTag(config.getParameter<edm::InputTag>("l1tResults")),
59  m_daqPartitions(config.getParameter<unsigned int>("daqPartitions")),
60  m_l1tIgnoreMask(config.getParameter<bool>("l1tIgnoreMask")),
61  m_l1techIgnorePrescales(config.getParameter<bool>("l1techIgnorePrescales")),
62  m_throw(config.getParameter<bool>("throw")),
63  // l1 values and status
64  m_l1tResults(0),
65  m_l1tMenu(0),
66  m_l1tAlgoMask(0),
67  m_l1tTechMask(0),
68  m_l1tCacheID(),
70  // hlt values and status
71  m_hltResults(0),
72  m_hltMenu(0),
73  m_hltCacheID(),
75  // event values
77  {
80  }
81 
82  // explicit c'tor from single arguments
84  edm::InputTag const & hltResultsTag,
85  edm::InputTag const & l1tResultsTag,
86  unsigned int daqPartitions,
87  bool l1tIgnoreMask,
88  bool l1techIgnorePrescales,
89  bool doThrow,
90  edm::ConsumesCollector && iC ) :
91  // configuration
92  m_hltResultsTag(hltResultsTag),
94  m_l1tResultsTag(l1tResultsTag),
96  m_daqPartitions(daqPartitions),
97  m_l1tIgnoreMask(l1tIgnoreMask),
98  m_l1techIgnorePrescales(l1techIgnorePrescales),
99  m_throw(doThrow),
100  // l1 values and status
101  m_l1tResults(0),
102  m_l1tMenu(0),
103  m_l1tAlgoMask(0),
104  m_l1tTechMask(0),
105  m_l1tCacheID(),
107  // hlt values and status
108  m_hltResults(0),
109  m_hltMenu(0),
110  m_hltCacheID(),
112  // event values
113  m_eventNumber()
114  {
117  }
118 
119  // set the new event
120  bool setEvent(const edm::Event & event, const edm::EventSetup & setup);
121 
122  // re-configuration accessors
123 
126  }
127 
130  }
131 
132  void setDaqPartitions(unsigned int daqPartitions) {
134  }
135 
136  void setL1tIgnoreMask(bool l1tIgnoreMask) {
137  m_l1tIgnoreMask = l1tIgnoreMask;
138  }
139 
140  void setL1techIgnorePrescales(bool l1techIgnorePrescales) {
141  m_l1techIgnorePrescales = l1techIgnorePrescales;
142  }
143 
144  void setThrow(bool doThrow) {
145  m_throw = doThrow;
146  }
147 
148  // read-only accessors
149 
150  bool hasL1T() const {
151  return not m_l1tResultsTag.label().empty();
152  }
153 
154  bool hasHLT() const {
155  return not m_hltResultsTag.label().empty();
156  }
157 
158  const edm::TriggerResults & hltResults() const {
159  return * m_hltResults;
160  }
161 
162  const edm::TriggerNames & hltMenu() const {
163  return * m_hltMenu;
164  }
165 
167  return * m_l1tResults;
168  }
169 
170  const L1GtTriggerMenu & l1tMenu() const {
171  return * m_l1tMenu;
172  }
173 
174  const L1GtTriggerMask & l1tAlgoMask() const {
175  return * m_l1tAlgoMask;
176  }
177 
178  const L1GtTriggerMask & l1tTechMask() const {
179  return * m_l1tTechMask;
180  }
181 
182  bool hltConfigurationUpdated() const {
183  return m_hltUpdated;
184  }
185 
186  bool l1tConfigurationUpdated() const {
187  return m_l1tUpdated;
188  }
189 
190  bool configurationUpdated() const {
192  }
193 
195  return m_eventNumber;
196  }
197 
198  bool shouldThrow() const {
199  return m_throw;
200  }
201 
202  bool ignoreL1Mask() const {
203  return m_l1tIgnoreMask;
204  }
205 
206  bool ignoreL1TechPrescales() const {
208  }
209 
210  unsigned int daqPartitions() const {
211  return m_daqPartitions;
212  }
213 
214 private:
215  // configuration
220  unsigned int m_daqPartitions;
223  bool m_throw;
224 
225  // l1 values and status
230  unsigned long long m_l1tCacheID;
232 
233  // hlt values and status
238 
239  // event values
241 };
242 
243 } // namespace triggerExpression
244 
245 #endif // HLTrigger_HLTfilters_TriggerExpressionData_h
void setDaqPartitions(unsigned int daqPartitions)
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::EventIDconst &, edm::Timestampconst & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
Definition: Activities.doc:12
const L1GtTriggerMask * m_l1tTechMask
void setL1tResultsTag(edm::InputTag const &tag)
Data(const edm::ParameterSet &config, edm::ConsumesCollector &&iC)
const L1GtTriggerMask & l1tTechMask() const
void setL1tIgnoreMask(bool l1tIgnoreMask)
const edm::TriggerNames & hltMenu() const
unsigned long long EventNumber_t
const L1GtTriggerMask * m_l1tAlgoMask
const L1GlobalTriggerReadoutRecord & l1tResults() const
const L1GtTriggerMenu & l1tMenu() const
edm::EventNumber_t eventNumber() const
const edm::TriggerResults * m_hltResults
void setHltResultsTag(edm::InputTag const &tag)
edm::EDGetTokenT< edm::TriggerResults > m_hltResultsToken
const edm::TriggerResults & hltResults() const
const edm::TriggerNames * m_hltMenu
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
void setL1techIgnorePrescales(bool l1techIgnorePrescales)
Data(edm::InputTag const &hltResultsTag, edm::InputTag const &l1tResultsTag, unsigned int daqPartitions, bool l1tIgnoreMask, bool l1techIgnorePrescales, bool doThrow, edm::ConsumesCollector &&iC)
const L1GlobalTriggerReadoutRecord * m_l1tResults
unsigned int daqPartitions() const
bool setEvent(const edm::Event &event, const edm::EventSetup &setup)
std::string const & label() const
Definition: InputTag.h:43
edm::ParameterSetID m_hltCacheID
edm::EDGetTokenT< L1GlobalTriggerReadoutRecord > m_l1tResultsToken
edm::EventNumber_t m_eventNumber
volatile std::atomic< bool > shutdown_flag false
const L1GtTriggerMenu * m_l1tMenu
unsigned long long m_l1tCacheID
void setup(std::vector< TH2F > &depth, std::string name, std::string units="")
const L1GtTriggerMask & l1tAlgoMask() const