RecoPixelVertexing
PixelLowPtUtilities
plugins
TrackCleanerESProducer.cc
Go to the documentation of this file.
1
// user include files
2
#include "
FWCore/Framework/interface/ModuleFactory.h
"
3
#include "
FWCore/Framework/interface/ESProducer.h
"
4
#include "
FWCore/Framework/interface/ESHandle.h
"
5
6
#include "
Geometry/Records/interface/TrackerTopologyRcd.h
"
7
8
#include "
RecoPixelVertexing/PixelLowPtUtilities/interface/TrackCleaner.h
"
9
10
class
TrackCleanerESProducer
:
public
edm::ESProducer
{
11
public
:
12
TrackCleanerESProducer
(
const
edm::ParameterSet
& iConfig);
13
~TrackCleanerESProducer
()
override
=
default
;
14
15
static
void
fillDescriptions
(
edm::ConfigurationDescriptions
& descriptions);
16
17
std::unique_ptr<PixelTrackCleaner>
produce
(
const
PixelTrackCleaner::Record
& iRecord);
18
19
private
:
20
const
edm::ESGetToken<TrackerTopology, TrackerTopologyRcd>
trackerToken_
;
21
};
22
23
TrackCleanerESProducer::TrackCleanerESProducer
(
const
edm::ParameterSet
& iConfig)
24
: trackerToken_(setWhatProduced(this, iConfig.getParameter<
std
::
string
>(
"ComponentName"
))
25
.consumesFrom<
TrackerTopology
,
TrackerTopologyRcd
>()) {}
26
27
void
TrackCleanerESProducer::fillDescriptions
(
edm::ConfigurationDescriptions
& descriptions) {
28
edm::ParameterSetDescription
desc
;
29
desc
.add<
std::string
>(
"ComponentName"
,
"trackCleaner"
);
30
descriptions.
add
(
"trackCleaner"
,
desc
);
31
}
32
33
std::unique_ptr<PixelTrackCleaner>
TrackCleanerESProducer::produce
(
const
PixelTrackCleaner::Record
& iRecord) {
34
return
std::make_unique<TrackCleaner>(&iRecord.
get
(
trackerToken_
));
35
}
36
37
#include "
FWCore/PluginManager/interface/ModuleDef.h
"
38
#include "
FWCore/Framework/interface/MakerMacros.h
"
39
DEFINE_FWK_EVENTSETUP_MODULE
(
TrackCleanerESProducer
);
TrackCleanerESProducer::TrackCleanerESProducer
TrackCleanerESProducer(const edm::ParameterSet &iConfig)
Definition:
TrackCleanerESProducer.cc:23
ESHandle.h
TrackerTopology
Definition:
TrackerTopology.h:16
edm::ParameterSetDescription
Definition:
ParameterSetDescription.h:52
ESProducer.h
MakerMacros.h
TrackCleanerESProducer::trackerToken_
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > trackerToken_
Definition:
TrackCleanerESProducer.cc:20
TrackerTopologyRcd.h
edm::ConfigurationDescriptions::add
void add(std::string const &label, ParameterSetDescription const &psetDescription)
Definition:
ConfigurationDescriptions.cc:57
CkfComponentsRecord
Definition:
CkfComponentsRecord.h:22
TrackCleanerESProducer
Definition:
TrackCleanerESProducer.cc:10
edm::eventsetup::DependentRecordImplementation::get
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
Definition:
DependentRecordImplementation.h:103
TrackCleaner.h
edm::ConfigurationDescriptions
Definition:
ConfigurationDescriptions.h:28
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
edm::ParameterSet
Definition:
ParameterSet.h:47
TrackCleanerESProducer::produce
std::unique_ptr< PixelTrackCleaner > produce(const PixelTrackCleaner::Record &iRecord)
Definition:
TrackCleanerESProducer.cc:33
ModuleDef.h
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd >
ModuleFactory.h
submitPVResolutionJobs.desc
string desc
Definition:
submitPVResolutionJobs.py:251
std
Definition:
JetResolutionObject.h:76
TrackCleanerESProducer::fillDescriptions
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
Definition:
TrackCleanerESProducer.cc:27
TrackCleanerESProducer::~TrackCleanerESProducer
~TrackCleanerESProducer() override=default
DEFINE_FWK_EVENTSETUP_MODULE
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
Definition:
ModuleFactory.h:60
edm::ESProducer
Definition:
ESProducer.h:104
TrackerTopologyRcd
Definition:
TrackerTopologyRcd.h:10
Generated for CMSSW Reference Manual by
1.8.16