#include <DataFormats/Common/interface/HLTGlobalStatus.h>
Public Member Functions | |
bool | accept (const unsigned int i) const |
Has ith path accepted the event? | |
bool | accept () const |
Has at least one path accepted the event? | |
HLTPathStatus & | at (const unsigned int i) |
const HLTPathStatus & | at (const unsigned int i) const |
bool | error (const unsigned int i) const |
Has ith path encountered an error (exception)? | |
bool | error () const |
Has any path encountered an error (exception). | |
HLTGlobalStatus (const unsigned int n=0) | |
Constructor - for n paths. | |
unsigned int | index (const unsigned int i) const |
Get index (slot position) of module giving the decision of the ith path. | |
HLTGlobalStatus & | operator= (HLTGlobalStatus const &rhs) |
copy assignment implemented with swap() | |
HLTPathStatus & | operator[] (const unsigned int i) |
const HLTPathStatus & | operator[] (const unsigned int i) const |
void | reset (const unsigned int i) |
Reset the ith path. | |
void | reset () |
Reset status for all paths. | |
unsigned int | size () const |
Get number of paths stored. | |
hlt::HLTState | state (const unsigned int i) const |
Get status of ith path. | |
void | swap (HLTGlobalStatus &other) |
swap function | |
bool | wasrun (const unsigned int i) const |
Was ith path run? | |
bool | wasrun () const |
Was at least one path run? | |
Private Member Functions | |
bool | State (unsigned int icase) const |
Global state variable calculated on the fly. | |
Private Attributes | |
std::vector< HLTPathStatus > | paths_ |
Status of each HLT path. |
If the user wants map-like indexing of HLT triggers through their names as key, s/he must use the TriggerNamesService.
Definition at line 28 of file HLTGlobalStatus.h.
edm::HLTGlobalStatus::HLTGlobalStatus | ( | const unsigned int | n = 0 |
) | [inline] |
Has ith path accepted the event?
Definition at line 68 of file HLTGlobalStatus.h.
References edm::HLTPathStatus::accept(), and at().
bool edm::HLTGlobalStatus::accept | ( | ) | const [inline] |
Has at least one path accepted the event?
Definition at line 54 of file HLTGlobalStatus.h.
References State().
Referenced by CaloMETAnalyzer::analyze(), and VisTriggerResultsTwig::onNewEvent().
00054 {return State(1);}
HLTPathStatus& edm::HLTGlobalStatus::at | ( | const unsigned int | i | ) | [inline] |
const HLTPathStatus& edm::HLTGlobalStatus::at | ( | const unsigned int | i | ) | const [inline] |
Has ith path encountered an error (exception)?
Definition at line 70 of file HLTGlobalStatus.h.
References at(), and edm::HLTPathStatus::error().
bool edm::HLTGlobalStatus::error | ( | ) | const [inline] |
Has any path encountered an error (exception).
Definition at line 56 of file HLTGlobalStatus.h.
References State().
Referenced by VisTriggerResultsTwig::onNewEvent().
00056 {return State(2);}
Get index (slot position) of module giving the decision of the ith path.
Definition at line 75 of file HLTGlobalStatus.h.
References at(), and edm::HLTPathStatus::index().
HLTGlobalStatus& edm::HLTGlobalStatus::operator= | ( | HLTGlobalStatus const & | rhs | ) | [inline] |
copy assignment implemented with swap()
Definition at line 81 of file HLTGlobalStatus.h.
References swap(), and pyDBSRunClass::temp.
00081 { 00082 HLTGlobalStatus temp(rhs); 00083 this->swap(temp); 00084 return *this; 00085 }
HLTPathStatus& edm::HLTGlobalStatus::operator[] | ( | const unsigned int | i | ) | [inline] |
const HLTPathStatus& edm::HLTGlobalStatus::operator[] | ( | const unsigned int | i | ) | const [inline] |
Reset the ith path.
Definition at line 77 of file HLTGlobalStatus.h.
References at(), and edm::HLTPathStatus::reset().
Get number of paths stored.
Definition at line 41 of file HLTGlobalStatus.h.
References paths_.
Referenced by CaloMETAnalyzer::analyze(), edm::EventSelector::containsExceptions(), edm::TriggerResults::find(), edm::service::TriggerNamesService::getTrigPaths(), HLTHighLevel::init(), edm::EventSelector::maskTriggerResults(), edm::operator<<(), reset(), and State().
00041 { return paths_.size(); }
Global state variable calculated on the fly.
Definition at line 90 of file HLTGlobalStatus.h.
References edm::hlt::Exception, flags, i, n, edm::hlt::Pass, edm::hlt::Ready, s, size(), and state().
Referenced by accept(), error(), and wasrun().
00090 { 00091 bool flags[3] = {false, false, false}; 00092 const unsigned int n(size()); 00093 for (unsigned int i = 0; i != n; ++i) { 00094 const hlt::HLTState s(state(i)); 00095 if (s!=hlt::Ready) { 00096 flags[0]=true; // at least one trigger was run 00097 if (s==hlt::Pass) { 00098 flags[1]=true; // at least one trigger accepted 00099 } else if (s==hlt::Exception) { 00100 flags[2]=true; // at least one trigger with error 00101 } 00102 } 00103 } 00104 return flags[icase]; 00105 }
hlt::HLTState edm::HLTGlobalStatus::state | ( | const unsigned int | i | ) | const [inline] |
Get status of ith path.
Definition at line 73 of file HLTGlobalStatus.h.
References at(), and edm::HLTPathStatus::state().
Referenced by edm::EventSelector::acceptAllBits(), edm::EventSelector::acceptOneBit(), edm::EventSelector::maskTriggerResults(), edm::operator<<(), and State().
void edm::HLTGlobalStatus::swap | ( | HLTGlobalStatus & | other | ) | [inline] |
swap function
Definition at line 79 of file HLTGlobalStatus.h.
References paths_.
Referenced by operator=(), edm::swap(), and std::swap().
00079 { paths_.swap(other.paths_); }
Was ith path run?
Definition at line 66 of file HLTGlobalStatus.h.
References at(), and edm::HLTPathStatus::wasrun().
bool edm::HLTGlobalStatus::wasrun | ( | ) | const [inline] |
Was at least one path run?
Definition at line 52 of file HLTGlobalStatus.h.
References State().
Referenced by VisTriggerResultsTwig::onNewEvent().
00052 {return State(0);}
std::vector<HLTPathStatus> edm::HLTGlobalStatus::paths_ [private] |
Status of each HLT path.
Definition at line 33 of file HLTGlobalStatus.h.
Referenced by at(), operator[](), reset(), size(), and swap().