DataFormats
PatCandidates
src
TriggerPath.cc
Go to the documentation of this file.
1
//
2
//
3
4
#include "
DataFormats/PatCandidates/interface/TriggerPath.h
"
5
6
using namespace
pat
;
7
8
// Constructors and Destructor
9
10
// Default constructor
11
TriggerPath::TriggerPath
()
12
: name_(), index_(), prescale_(), run_(), accept_(), error_(), lastActiveFilterSlot_(), l3Filters_(0) {
13
modules_
.clear();
14
filterIndices_
.clear();
15
}
16
17
// Constructor from path name only
18
TriggerPath::TriggerPath
(
const
std::string
&
name
)
19
: name_(
name
), index_(), prescale_(), run_(), accept_(), error_(), lastActiveFilterSlot_(), l3Filters_(0) {
20
modules_
.clear();
21
filterIndices_
.clear();
22
}
23
24
// Constructor from values
25
TriggerPath::TriggerPath
(
const
std::string
&
name
,
26
unsigned
index
,
27
unsigned
prescale
,
28
bool
run
,
29
bool
accept
,
30
bool
error
,
31
unsigned
lastActiveFilterSlot,
32
unsigned
l3Filters)
33
: name_(
name
),
34
index_(
index
),
35
prescale_(
prescale
),
36
run_(
run
),
37
accept_(
accept
),
38
error_(
error
),
39
lastActiveFilterSlot_(lastActiveFilterSlot),
40
l3Filters_(l3Filters) {
41
modules_
.clear();
42
filterIndices_
.clear();
43
}
44
45
// Methods
46
47
// Get the index of a certain module
48
int
TriggerPath::indexModule
(
const
std::string
&
name
)
const
{
49
if
(
modules_
.begin() ==
modules_
.end())
50
return
-1;
51
return
(
std::find
(
modules_
.begin(),
modules_
.end(),
name
) -
modules_
.begin());
52
}
53
54
// Get names of all L1 seeds with a certain decision
55
std::vector<std::string>
TriggerPath::l1Seeds
(
const
bool
decision)
const
{
56
std::vector<std::string>
seeds
;
57
for
(L1SeedCollection::const_iterator iSeed =
l1Seeds
().begin(); iSeed !=
l1Seeds
().end(); ++iSeed) {
58
if
(iSeed->first == decision)
59
seeds
.push_back(iSeed->second);
60
}
61
return
seeds
;
62
}
pat::TriggerPath::TriggerPath
TriggerPath()
Constructors and Desctructor.
Definition:
TriggerPath.cc:11
pat::TriggerPath::filterIndices_
std::vector< unsigned > filterIndices_
Definition:
TriggerPath.h:60
pat::TriggerPath::indexModule
int indexModule(const std::string &name) const
Definition:
TriggerPath.cc:48
spr::find
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition:
FindCaloHit.cc:19
relativeConstraints.error
error
Definition:
relativeConstraints.py:53
accept
bool accept(const edm::Event &event, const edm::TriggerResults &triggerTable, const std::string &triggerPath)
Definition:
TopDQMHelpers.h:31
pat::TriggerPath::modules_
std::vector< std::string > modules_
Definition:
TriggerPath.h:55
pat::TriggerPath::name
const std::string & name() const
Get the path name.
Definition:
TriggerPath.h:115
pat
Definition:
HeavyIon.h:7
prescale
Definition:
PrescaleEventFilter.cc:32
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
writedatasetfile.run
run
Definition:
writedatasetfile.py:27
DetachedQuadStep_cff.seeds
seeds
Definition:
DetachedQuadStep_cff.py:195
Skims_PA_cff.name
name
Definition:
Skims_PA_cff.py:17
pat::TriggerPath::l1Seeds
const L1SeedCollection & l1Seeds() const
Get all L1 seeds.
Definition:
TriggerPath.h:143
AlignmentPI::index
index
Definition:
AlignmentPayloadInspectorHelper.h:46
TriggerPath.h
Generated for CMSSW Reference Manual by
1.8.16