RecoLocalMuon
RPCRecHit
src
DTObjectMapESProducer.cc
Go to the documentation of this file.
1
// system include files
2
#include <memory>
3
4
// user include files
5
#include "
FWCore/Framework/interface/ESProducer.h
"
6
#include "
FWCore/Framework/interface/ESHandle.h
"
7
#include "
FWCore/ParameterSet/interface/ParameterSet.h
"
8
#include "
FWCore/ParameterSet/interface/ParameterSetDescription.h
"
9
#include "
FWCore/ParameterSet/interface/ConfigurationDescriptions.h
"
10
#include "
Geometry/Records/interface/MuonGeometryRecord.h
"
11
#include "
RecoLocalMuon/RPCRecHit/src/DTObjectMap.h
"
12
13
class
DTObjectMapESProducer
:
public
edm::ESProducer
{
14
public
:
15
DTObjectMapESProducer
(
const
edm::ParameterSet
&) :
rpcGeomToken_
(
setWhatProduced
(this).consumes<
RPCGeometry
>()) {}
16
17
std::unique_ptr<DTObjectMap>
produce
(
MuonGeometryRecord
const
&
record
) {
18
return
std::make_unique<DTObjectMap>(
record
.get(
rpcGeomToken_
));
19
}
20
21
static
void
fillDescriptions
(
edm::ConfigurationDescriptions
& descriptions) {
22
edm::ParameterSetDescription
desc;
23
descriptions.
add
(
"dtObjectMapESProducer"
, desc);
24
}
25
26
private
:
27
const
edm::ESGetToken<RPCGeometry, MuonGeometryRecord>
rpcGeomToken_
;
28
};
29
30
//define this as a plug-in
31
#include "
FWCore/Framework/interface/ModuleFactory.h
"
32
DEFINE_FWK_EVENTSETUP_MODULE
(
DTObjectMapESProducer
);
ConfigurationDescriptions.h
ESHandle.h
edm::ESProducer::setWhatProduced
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition:
ESProducer.h:138
edm::ParameterSetDescription
Definition:
ParameterSetDescription.h:52
ESProducer.h
GlobalPosition_Frontier_DevDB_cff.record
record
Definition:
GlobalPosition_Frontier_DevDB_cff.py:10
DTObjectMapESProducer::fillDescriptions
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
Definition:
DTObjectMapESProducer.cc:21
edm::ConfigurationDescriptions::add
void add(std::string const &label, ParameterSetDescription const &psetDescription)
Definition:
ConfigurationDescriptions.cc:57
DTObjectMap.h
ParameterSetDescription.h
DTObjectMapESProducer::DTObjectMapESProducer
DTObjectMapESProducer(const edm::ParameterSet &)
Definition:
DTObjectMapESProducer.cc:15
edm::ConfigurationDescriptions
Definition:
ConfigurationDescriptions.h:28
DTObjectMapESProducer::rpcGeomToken_
const edm::ESGetToken< RPCGeometry, MuonGeometryRecord > rpcGeomToken_
Definition:
DTObjectMapESProducer.cc:27
edm::ParameterSet
Definition:
ParameterSet.h:36
DTObjectMapESProducer
Definition:
DTObjectMapESProducer.cc:13
edm::ESGetToken< RPCGeometry, MuonGeometryRecord >
DTObjectMapESProducer::produce
std::unique_ptr< DTObjectMap > produce(MuonGeometryRecord const &record)
Definition:
DTObjectMapESProducer.cc:17
ModuleFactory.h
DEFINE_FWK_EVENTSETUP_MODULE
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
Definition:
ModuleFactory.h:60
edm::ESProducer
Definition:
ESProducer.h:101
RPCGeometry
Definition:
RPCGeometry.h:20
ParameterSet.h
MuonGeometryRecord.h
MuonGeometryRecord
Definition:
MuonGeometryRecord.h:34
Generated for CMSSW Reference Manual by
1.8.16