Main Page
Namespaces
Classes
Package Documentation
CommonTools
ParticleFlow
interface
GenericPFJetSelectorDefinition.h
Go to the documentation of this file.
1
#ifndef CommonTools_ParticleFlow_GenericPFJetSelectorDefinition
2
#define CommonTools_ParticleFlow_GenericPFJetSelectorDefinition
3
4
5
#include "
FWCore/Framework/interface/ConsumesCollector.h
"
6
#include "
DataFormats/JetReco/interface/PFJet.h
"
7
#include "
DataFormats/ParticleFlowCandidate/interface/PFCandidateFwd.h
"
8
#include "
CommonTools/ParticleFlow/interface/PFJetSelectorDefinition.h
"
9
#include "
CommonTools/Utils/interface/StringCutObjectSelector.h
"
10
11
namespace
pf2pat
{
12
13
struct
GenericPFJetSelectorDefinition
:
public
PFJetSelectorDefinition
{
14
15
GenericPFJetSelectorDefinition
(
const
edm::ParameterSet
&
cfg
,
edm::ConsumesCollector
&& iC ) :
16
selector_
( cfg.getParameter<
std
::
string
>(
"cut"
) ) { }
17
18
void
select
(
const
HandleToCollection
&
hc
,
19
const
edm::Event
&
e
,
20
const
edm::EventSetup
&
s
) {
21
selected_
.clear();
22
23
unsigned
key
=0;
24
for
( collection::const_iterator pfc = hc->begin();
25
pfc != hc->end(); ++pfc, ++
key
) {
26
27
if
(
selector_
(*pfc) ) {
28
selected_
.push_back(
reco::PFJet
(*pfc) );
29
reco::CandidatePtr
ptrToMother( hc, key );
30
selected_
.back().setSourceCandidatePtr( ptrToMother );
31
32
}
33
}
34
}
35
36
private
:
37
StringCutObjectSelector<reco::PFJet>
selector_
;
38
};
39
}
40
41
#endif
pf2pat::GenericPFJetSelectorDefinition::GenericPFJetSelectorDefinition
GenericPFJetSelectorDefinition(const edm::ParameterSet &cfg, edm::ConsumesCollector &&iC)
Definition:
GenericPFJetSelectorDefinition.h:15
PFJetSelectorDefinition.h
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:255
StringCutObjectSelector< reco::PFJet >
alignCSCRings.s
s
Definition:
alignCSCRings.py:91
edm::Handle
Definition:
AssociativeIterator.h:47
std
Definition:
JetResolutionObject.h:76
MillePedeFileConverter_cfg.e
e
Definition:
MillePedeFileConverter_cfg.py:37
crabWrapper.key
key
Definition:
crabWrapper.py:17
reco::PFJet
Jets made from PFObjects.
Definition:
PFJet.h:21
pf2pat::GenericPFJetSelectorDefinition::select
void select(const HandleToCollection &hc, const edm::Event &e, const edm::EventSetup &s)
Definition:
GenericPFJetSelectorDefinition.h:18
StringCutObjectSelector.h
pf2pat::GenericPFJetSelectorDefinition
Definition:
GenericPFJetSelectorDefinition.h:13
edm::EventSetup
Definition:
EventSetup.h:45
edm::Ptr< Candidate >
looper.cfg
cfg
Definition:
looper.py:293
pf2pat::PFJetSelectorDefinition
Definition:
PFJetSelectorDefinition.h:11
pf2pat::GenericPFJetSelectorDefinition::selector_
StringCutObjectSelector< reco::PFJet > selector_
Definition:
GenericPFJetSelectorDefinition.h:37
pf2pat
Definition:
ElectronIDPFCandidateSelectorDefinition.h:20
pf2pat::PFJetSelectorDefinition::selected_
container selected_
Definition:
PFJetSelectorDefinition.h:35
AnalysisDataFormats_SUSYBSMObjects::hc
susybsm::HSCParticleCollection hc
Definition:
classes.h:25
edm::ParameterSet
Definition:
ParameterSet.h:36
edm::Event
Definition:
Event.h:66
PFCandidateFwd.h
ConsumesCollector.h
edm::ConsumesCollector
Definition:
ConsumesCollector.h:39
PFJet.h
Generated for CMSSW Reference Manual by
1.8.11