FWCore
Common
src
TriggerNames.cc
Go to the documentation of this file.
1
2
#include "
FWCore/Common/interface/TriggerNames.h
"
3
#include "
FWCore/ParameterSet/interface/ParameterSet.h
"
4
5
namespace
edm
{
6
7
TriggerNames::TriggerNames
() {}
8
9
TriggerNames::TriggerNames
(
edm::ParameterSet
const
&
pset
) {
10
triggerNames_
=
pset
.getParameter<
Strings
>(
"@trigger_paths"
);
11
12
unsigned
int
index
= 0;
13
for
(Strings::const_iterator iName =
triggerNames_
.begin(), iEnd =
triggerNames_
.end(); iName != iEnd;
14
++iName, ++
index
) {
15
indexMap_
[*iName] =
index
;
16
}
17
psetID_
=
pset
.id();
18
}
19
20
TriggerNames::Strings
const
&
TriggerNames::triggerNames
()
const
{
return
triggerNames_
; }
21
22
std::string
const
&
TriggerNames::triggerName
(
unsigned
int
index
)
const
{
return
triggerNames_
.at(
index
); }
23
24
unsigned
int
TriggerNames::triggerIndex
(
const
std::string
&
name
)
const
{
25
IndexMap::const_iterator
const
pos
=
indexMap_
.find(
name
);
26
if
(
pos
==
indexMap_
.end())
27
return
indexMap_
.size();
28
return
pos
->second;
29
}
30
31
TriggerNames::Strings::size_type
TriggerNames::size
()
const
{
return
triggerNames_
.size(); }
32
33
ParameterSetID
const
&
TriggerNames::parameterSetID
()
const
{
return
psetID_
; }
34
}
// namespace edm
edm::TriggerNames::TriggerNames
TriggerNames()
Definition:
TriggerNames.cc:7
edm::TriggerNames::parameterSetID
ParameterSetID const & parameterSetID() const
Definition:
TriggerNames.cc:33
edm
HLT enums.
Definition:
AlignableModifier.h:19
pos
Definition:
PixelAliasList.h:18
edm::TriggerNames::triggerNames_
Strings triggerNames_
Definition:
TriggerNames.h:85
edm::TriggerNames::Strings
std::vector< std::string > Strings
Definition:
TriggerNames.h:57
trigger::size_type
uint16_t size_type
Definition:
TriggerTypeDefs.h:18
edm::TriggerNames::indexMap_
IndexMap indexMap_
Definition:
TriggerNames.h:86
edm::Hash< ParameterSetType >
edm::TriggerNames::triggerNames
Strings const & triggerNames() const
Definition:
TriggerNames.cc:20
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
edm::ParameterSet
Definition:
ParameterSet.h:47
TriggerNames.h
edm::TriggerNames::triggerName
std::string const & triggerName(unsigned int index) const
Definition:
TriggerNames.cc:22
edm::TriggerNames::psetID_
ParameterSetID psetID_
Definition:
TriggerNames.h:83
edm::TriggerNames::size
Strings::size_type size() const
Definition:
TriggerNames.cc:31
Skims_PA_cff.name
name
Definition:
Skims_PA_cff.py:17
AlignmentPI::index
index
Definition:
AlignmentPayloadInspectorHelper.h:46
ParameterSet.h
edm::TriggerNames::triggerIndex
unsigned int triggerIndex(std::string const &name) const
Definition:
TriggerNames.cc:24
muonDTDigis_cfi.pset
pset
Definition:
muonDTDigis_cfi.py:27
Generated for CMSSW Reference Manual by
1.8.16