41 nameHltTable_( nameHltTable ),
45 physDecl_( physDecl ) ,
63 nameL1Menu_( nameL1Menu ),
64 nameHltTable_( nameHltTable ),
68 physDecl_( physDecl ) ,
91 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
103 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
104 if ( nameAlgorithm == iAlgorithm->name() )
return &*iAlgorithm;
114 if ( nameAlgorithm == ( *iAlgorithm )->name() )
return *iAlgorithm;
123 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
124 if ( bitAlgorithm == iAlgorithm->bit() && techAlgorithm == iAlgorithm->techTrigger() )
return iAlgorithm->name();
126 return std::string(
"" );
133 unsigned iAlgorithm( 0 );
143 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
144 if ( iAlgorithm->decision() ) {
147 theAcceptedAlgorithms.
push_back( algorithmRef );
150 return theAcceptedAlgorithms;
158 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
159 if ( iAlgorithm->gtlResult() ) {
162 theAcceptedAlgorithms.
push_back( algorithmRef );
165 return theAcceptedAlgorithms;
173 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
174 if ( iAlgorithm->techTrigger() ) {
177 theTechAlgorithms.
push_back( algorithmRef );
180 return theTechAlgorithms;
188 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
189 if ( iAlgorithm->techTrigger() && iAlgorithm->decision() ) {
192 theAcceptedTechAlgorithms.
push_back( algorithmRef );
195 return theAcceptedTechAlgorithms;
203 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
204 if ( iAlgorithm->techTrigger() && iAlgorithm->gtlResult() ) {
207 theAcceptedTechAlgorithms.
push_back( algorithmRef );
210 return theAcceptedTechAlgorithms;
218 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
219 if ( ! iAlgorithm->techTrigger() ) {
222 thePhysAlgorithms.
push_back( algorithmRef );
225 return thePhysAlgorithms;
233 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
234 if ( ! iAlgorithm->techTrigger() && iAlgorithm->decision() ) {
237 theAcceptedPhysAlgorithms.
push_back( algorithmRef );
240 return theAcceptedPhysAlgorithms;
248 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
249 if ( ! iAlgorithm->techTrigger() && iAlgorithm->gtlResult() ) {
252 theAcceptedPhysAlgorithms.
push_back( algorithmRef );
255 return theAcceptedPhysAlgorithms;
263 for ( TriggerConditionCollection::const_iterator iCondition =
conditions()->
begin(); iCondition !=
conditions()->end(); ++iCondition ) {
264 const std::string nameCondition( iCondition->name() );
268 return theConditions;
275 for ( TriggerConditionCollection::const_iterator iCondition =
conditions()->
begin(); iCondition !=
conditions()->end(); ++iCondition ) {
276 if ( nameCondition == iCondition->name() )
return &*iCondition;
286 if ( nameCondition == ( *iCondition )->name() )
return *iCondition;
295 unsigned iCondition( 0 );
305 for ( TriggerConditionCollection::const_iterator iCondition =
conditions()->
begin(); iCondition !=
conditions()->end(); ++iCondition ) {
306 if ( iCondition->wasAccept() ) {
307 const std::string nameCondition( iCondition->name() );
309 theAcceptedConditions.
push_back( conditionRef );
312 return theAcceptedConditions;
320 for ( TriggerPathCollection::const_iterator iPath =
paths()->
begin(); iPath !=
paths()->end(); ++iPath ) {
321 const std::string namePath( iPath->name() );
332 for ( TriggerPathCollection::const_iterator iPath =
paths()->
begin(); iPath !=
paths()->end(); ++iPath ) {
333 if ( namePath == iPath->name() )
return &*iPath;
343 if ( namePath == ( *iPath )->name() )
return *iPath;
362 for ( TriggerPathCollection::const_iterator iPath =
paths()->
begin(); iPath !=
paths()->end(); ++iPath ) {
363 if ( iPath->wasAccept() ) {
364 const std::string namePath( iPath->name() );
369 return theAcceptedPaths;
377 for ( TriggerFilterCollection::const_iterator iFilter =
filters()->
begin(); iFilter !=
filters()->end(); ++iFilter ) {
378 const std::string labelFilter( iFilter->label() );
389 for ( TriggerFilterCollection::const_iterator iFilter =
filters()->
begin(); iFilter !=
filters()->end(); ++iFilter ) {
390 if ( labelFilter == iFilter->label() )
return &*iFilter;
400 if ( labelFilter == ( *iFilter )->label() )
return *iFilter;
409 unsigned iFilter( 0 );
419 for ( TriggerFilterCollection::const_iterator iFilter =
filters()->
begin(); iFilter !=
filters()->end(); ++iFilter ) {
420 if ( iFilter->status() == 1 ) {
421 const std::string labelFilter( iFilter->label() );
423 theAcceptedFilters.
push_back( filterRef );
426 return theAcceptedFilters;
434 for (
unsigned iObject = 0; iObject <
objects()->size(); ++iObject ) {
446 for (
unsigned iObject = 0; iObject <
objects()->size(); ++iObject ) {
447 if (
objects()->at( iObject ).hasTriggerObjectType( triggerObjectType ) ) {
461 for (
unsigned iC = 0; iC < algorithmPtr->conditionKeys().size(); ++iC ) {
466 return theAlgorithmConditions;
475 if ( conditionRef == *iCondition )
return true;
485 size_t cAlgorithms( 0 );
486 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
490 theConditionAlgorithms.
push_back( algorithmRef );
494 return theConditionAlgorithms;
501 std::vector< std::string > theConditionCollections;
503 for (
unsigned iObject = 0; iObject <
objects()->size(); ++iObject ) {
504 if ( conditionPtr->hasObjectKey( iObject ) ) {
507 for ( std::vector< std::string >::const_iterator iC = theConditionCollections.begin(); iC != theConditionCollections.end(); ++iC ) {
508 if ( *iC == objectCollection ) {
514 theConditionCollections.push_back( objectCollection );
519 return theConditionCollections;
528 for (
unsigned iObject = 0; iObject <
objects()->size(); ++iObject ) {
529 if ( conditionPtr->hasObjectKey( iObject ) ) {
531 theConditionObjects.
push_back( objectRef );
535 return theConditionObjects;
550 for ( TriggerConditionCollection::const_iterator iCondition =
conditions()->
begin(); iCondition !=
conditions()->end(); ++iCondition ) {
551 const std::string nameCondition( iCondition->name() );
554 theObjectConditions.
push_back( conditionRef );
557 return theObjectConditions;
567 const std::string nameCondition( ( *iCondition )->name() );
570 theAlgorithmObjects.
push_back( *iObject );
573 return theAlgorithmObjects;
592 for ( TriggerAlgorithmCollection::const_iterator iAlgorithm =
algorithms()->
begin(); iAlgorithm !=
algorithms()->end(); ++iAlgorithm ) {
596 theObjectAlgorithms.
push_back( algorithmRef );
599 return theObjectAlgorithms;
608 if ( pathPtr->modules().size() > 0 ) {
609 const unsigned onePastLastFilter = all ? pathPtr->modules().
size() : pathPtr->lastActiveFilterSlot() + 1;
610 for (
unsigned iM = 0; iM < onePastLastFilter; ++iM ) {
611 const std::string labelFilter( pathPtr->modules().at( iM ) );
617 return thePathFilters;
626 for (
unsigned iF = 0; iF < pathPtr->filterIndices().size(); ++iF ) {
631 return thePathFilters;
640 if ( filterRef == *iFilter )
return true;
651 for ( TriggerPathCollection::const_iterator iPath =
paths()->
begin(); iPath !=
paths()->end(); ++iPath ) {
652 const std::string namePath( iPath->name() );
659 return theFilterPaths;
666 std::vector< std::string > theFilterCollections;
668 for (
unsigned iObject = 0; iObject <
objects()->size(); ++iObject ) {
669 if ( filterPtr->hasObjectKey( iObject ) ) {
672 for ( std::vector< std::string >::const_iterator iC = theFilterCollections.begin(); iC != theFilterCollections.end(); ++iC ) {
673 if ( *iC == objectCollection ) {
679 theFilterCollections.push_back( objectCollection );
684 return theFilterCollections;
693 for (
unsigned iObject = 0; iObject <
objects()->size(); ++iObject ) {
694 if ( filterPtr->hasObjectKey( iObject ) ) {
700 return theFilterObjects;
706 if (
const TriggerFilter * filterPtr =
filter( labelFilter ) )
return filterPtr->hasObjectKey( objectRef.
key() );
715 for ( TriggerFilterCollection::const_iterator iFilter =
filters()->
begin(); iFilter !=
filters()->end(); ++iFilter ) {
716 const std::string labelFilter( iFilter->label() );
719 if ( ( ! firing ) || iFilter->isFiring() ) theObjectFilters.
push_back( filterRef );
722 return theObjectFilters;
732 const std::string labelFilter( ( *iFilter )->label() );
738 return thePathObjects;
747 if (
objectInFilter( objectRef, ( *iFilter )->label() ) )
return true;
757 for ( TriggerPathCollection::const_iterator iPath =
paths()->
begin(); iPath !=
paths()->end(); ++iPath ) {
758 const std::string namePath( iPath->name() );
764 return theObjectPaths;
782 std::vector< std::string > theMatchers;
const TriggerObjectMatchContainer * triggerObjectMatchResults() const
Get all trigger matches.
TriggerConditionRefVector algorithmConditions(const std::string &nameAlgorithm) const
Analysis-level L1 trigger algorithm class.
TriggerAlgorithmRefVector physAlgorithms() const
Get a vector of references to all physics L1 algorithms.
TriggerAlgorithmRefVector acceptedAlgorithmsGtl() const
Get a vector of references to all L1 algorithms succeeding on the GTL board.
TriggerConditionRefVector objectConditions(const TriggerObjectRef &objectRef) const
Get a vector of references to all conditions, which have a certain object assigned.
TriggerConditionRefProd conditions_
Reference to pat::TriggerConditionCollection in event.
const TriggerObjectRefVector objectRefs() const
std::vector< std::string > triggerMatchers() const
Get a list of all linked trigger matches.
bool objectInPath(const TriggerObjectRef &objectRef, const std::string &namePath, bool firing=true) const
Checks, if an object was used in a certain path given by name.
const TriggerPathRef pathRef(const std::string &namePath) const
const TriggerCondition * condition(const std::string &nameCondition) const
const TriggerConditionCollection * conditions() const
TriggerFilterRefVector acceptedFilters() const
Get a vector of references to all succeeding HLT filters.
const TriggerFilterRefVector filterRefs() const
TriggerAlgorithmRefVector acceptedTechAlgorithms() const
Get a vector of references to all succeeding technical L1 algorithms.
TriggerFilterRefVector pathFilters(const std::string &namePath, bool firing=true) const
Get a vector of references to all active HLT filters assigned to a certain path given by name...
TriggerEvent()
Constructors and Desctructor.
TriggerPathRefProd paths_
Reference to pat::TriggerPathCollection in event.
TriggerAlgorithmRefVector objectAlgorithms(const TriggerObjectRef &objectRef) const
Get a vector of references to all algorithms, which have a certain object assigned.
const_iterator end() const
Termination of iteration.
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
bool accept(const edm::Event &event, const edm::TriggerResults &triggerTable, const std::string &triggerPath)
const TriggerPathCollection * paths() const
unsigned indexFilter(const std::string &labelFilter) const
edm::Ref< TriggerPathCollection > TriggerPathRef
Persistent reference to an item in a TriggerPathCollection.
TriggerFilterRefVector pathModules(const std::string &namePath, bool all=true) const
bool objectInAlgorithm(const TriggerObjectRef &objectRef, const std::string &nameAlgorithm) const
Checks, if an object was used in a certain algorithm given by name.
const_iterator begin() const
Initialize an iterator over the RefVector.
TriggerConditionRefVector acceptedConditions() const
Get a vector of references to all succeeding L1 condition.
TriggerAlgorithmRefProd algorithms_
edm::Ref< TriggerConditionCollection > TriggerConditionRef
Persistent reference to an item in a TriggerConditionCollection.
TriggerObjectRefVector filterObjects(const std::string &labelFilter) const
Get a vector of references to all objects, which were used in a certain filter given by name...
const TriggerObjectCollection * objects() const
unsigned indexAlgorithm(const std::string &nameAlgorithm) const
Analysis-level HLTrigger filter class.
bool filterInPath(const TriggerFilterRef &filterRef, const std::string &namePath, bool firing=true) const
Checks, if a filter is assigned to and was run in a certain path given by name.
edm::Ref< TriggerFilterCollection > TriggerFilterRef
Persistent reference to an item in a TriggerFilterCollection.
unsigned indexCondition(const std::string &nameCondition) const
Analysis-level L1 trigger condition class.
Analysis-level HLTrigger path class.
bool addObjectMatchResult(const TriggerObjectMatchRefProd &trigMatches, const std::string &labelMatcher)
TriggerObjectRefVector pathObjects(const std::string &namePath, bool firing=true) const
Get a vector of references to all objects, which were used in a certain path given by name...
const TriggerPath * path(const std::string &namePath) const
const TriggerFilterRef filterRef(const std::string &labelFilter) const
TriggerAlgorithmRefVector techAlgorithms() const
Get a vector of references to all technical L1 algorithms.
bool objectInCondition(const TriggerObjectRef &objectRef, const std::string &nameCondition) const
Checks, if an object was used in a certain condition given by name.
TriggerAlgorithmRefVector acceptedPhysAlgorithms() const
Get a vector of references to all succeeding physics L1 algorithms.
const TriggerAlgorithmCollection * algorithms() const
TriggerAlgorithmRefVector acceptedAlgorithms() const
Get a vector of references to all succeeding L1 algorithms.
const TriggerObjectMatch * triggerObjectMatchResult(const std::string &labelMatcher) const
TriggerFilterRefVector objectFilters(const TriggerObjectRef &objectRef, bool firing=true) const
Get a vector of references to all filters, which have a certain object assigned.
std::vector< std::string > conditionCollections(const std::string &nameAlgorithm) const
Get a list of all trigger object collections used in a certain condition given by name...
TriggerAlgorithmRefVector conditionAlgorithms(const TriggerConditionRef &conditionRef) const
Get a vector of references to all algorithms, which have a certain condition assigned.
edm::Ref< TriggerAlgorithmCollection > TriggerAlgorithmRef
Persistent reference to an item in a TriggerAlgorithmCollection.
TriggerFilterRefProd filters_
Reference to pat::TriggerAlgorithmCollection in event.
std::string nameAlgorithm(const unsigned bitAlgorithm, const bool techAlgorithm=true) const
const TriggerAlgorithmRef algorithmRef(const std::string &nameAlgorithm) const
TriggerPathRefVector objectPaths(const TriggerObjectRef &objectRef, bool firing=true) const
Get a vector of references to all paths, which have a certain object assigned.
std::vector< std::string > filterCollections(const std::string &labelFilter) const
Get a list of all trigger object collections used in a certain filter given by name.
const TriggerFilterCollection * filters() const
bool objectInFilter(const TriggerObjectRef &objectRef, const std::string &labelFilter) const
Checks, if an object was used in a certain filter given by name.
const TriggerAlgorithmRefVector algorithmRefs() const
TriggerObjectRefVector conditionObjects(const std::string &nameCondition) const
Get a vector of references to all objects, which were used in a certain condition given by name...
key_type key() const
Accessor for product key.
TriggerObjectRefVector algorithmObjects(const std::string &nameAlgorithm) const
Get a vector of references to all objects, which were used in a certain algorithm given by name...
TriggerAlgorithmRefVector acceptedPhysAlgorithmsGtl() const
Get a vector of references to all physics L1 algorithms succeeding on the GTL board.
TriggerAlgorithmRefVector acceptedTechAlgorithmsGtl() const
Get a vector of references to all technical L1 algorithms succeeding on the GTL board.
const TriggerConditionRefVector conditionRefs() const
const TriggerAlgorithm * algorithm(const std::string &nameAlgorithm) const
void push_back(value_type const &ref)
Add a Ref<C, T> to the RefVector.
TriggerPathRefVector filterPaths(const TriggerFilterRef &filterRef, bool firing=true) const
Get a vector of references to all paths, which have a certain filter assigned.
size_type size() const
Size of the RefVector.
TriggerObjectRefProd objects_
Reference to pat::TriggerObjectCollection in event.
const TriggerFilter * filter(const std::string &labelFilter) const
bool conditionInAlgorithm(const TriggerConditionRef &conditionRef, const std::string &nameAlgorithm) const
Checks, if a condition is assigned to a certain algorithm given by name.
TriggerObjectMatchContainer objectMatchResults_
Table of references to pat::TriggerObjectMatch associations in event.
const TriggerConditionRef conditionRef(const std::string &nameCondition) const
tuple size
Write out results.
TriggerPathRefVector acceptedPaths() const
Get a vector of references to all succeeding HLT paths.
unsigned indexPath(const std::string &namePath) const
const TriggerPathRefVector pathRefs() const