CMS 3D CMS Logo

L1TMuonOverlapParamsDBProducer.cc
Go to the documentation of this file.
3 
5 
6 #include <memory>
7 
10 
13 
18  const L1TMuonOverlapParamsRcd& omtfParamsRcd = iSetup.get<L1TMuonOverlapParamsRcd>();
19 
20  edm::ESHandle<L1TMuonOverlapParams> omtfParamsHandle;
21 
22  omtfParamsRcd.get("params", omtfParamsHandle);
23 
24  omtfParams = std::make_unique<L1TMuonOverlapParams>(*omtfParamsHandle.product());
25  if (!omtfParams) {
26  edm::LogError("L1TMuonOverlapTrackProducer") << "Could not retrieve parameters from Event Setup" << std::endl;
27  }
28 }
32  std::string recordName = "L1TMuonOverlapParamsRcd";
34  if (poolDbService.isAvailable()) {
35  poolDbService->writeOne(omtfParams.get(), poolDbService->currentTime(), recordName);
36  }
37 }
L1TMuonOverlapParamsRcd
Definition: L1TMuonOverlapParamsRcd.h:23
L1MuonOverlapParamsDBProducer::L1MuonOverlapParamsDBProducer
L1MuonOverlapParamsDBProducer(const edm::ParameterSet &cfg)
Definition: L1TMuonOverlapParamsDBProducer.cc:14
MessageLogger.h
ESHandle.h
edm::Run
Definition: Run.h:45
align_cfg.recordName
recordName
Definition: align_cfg.py:66
edm::Service::isAvailable
bool isAvailable() const
Definition: Service.h:40
MakerMacros.h
PoolDBOutputService.h
edm::EventSetup::get
T get() const
Definition: EventSetup.h:80
DEFINE_FWK_MODULE
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
L1MuonOverlapParamsDBProducer
Definition: L1TMuonOverlapParamsDBProducer.h:15
L1TMuonOverlapParamsDBProducer.h
Service.h
edm::ESHandle
Definition: DTSurvey.h:22
L1TMuonOverlapParams.h
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
edm::ParameterSet
Definition: ParameterSet.h:47
L1MuonOverlapParamsDBProducer::omtfParams
std::unique_ptr< L1TMuonOverlapParams > omtfParams
Definition: L1TMuonOverlapParamsDBProducer.h:22
edm::Service< cond::service::PoolDBOutputService >
L1MuonOverlapParamsDBProducer::analyze
void analyze(const edm::Event &, const edm::EventSetup &es) override
Definition: L1TMuonOverlapParamsDBProducer.cc:31
edm::EventSetup
Definition: EventSetup.h:57
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
looper.cfg
cfg
Definition: looper.py:297
writedatasetfile.run
run
Definition: writedatasetfile.py:27
L1MuonOverlapParamsDBProducer::beginRun
void beginRun(const edm::Run &, const edm::EventSetup &es) override
Definition: L1TMuonOverlapParamsDBProducer.cc:17
ev
bool ev
Definition: Hydjet2Hadronizer.cc:95
cond::service::PoolDBOutputService::writeOne
Hash writeOne(const T *payload, Time_t time, const std::string &recordName)
Definition: PoolDBOutputService.h:63
edm::eventsetup::EventSetupRecordImplementation::get
PRODUCT const & get(ESGetToken< PRODUCT, T > const &iToken) const
Definition: EventSetupRecordImplementation.h:74
L1TMuonOverlapParamsRcd.h
edm::Event
Definition: Event.h:73
cond::service::PoolDBOutputService::currentTime
cond::Time_t currentTime() const
Definition: PoolDBOutputService.cc:217