CMS 3D CMS Logo

HcalDDDRecConstantsESMoudle.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: HcalDDDRecConstantsESModule
4 // Class: HcalDDDRecConstantsESModule
5 //
13 //
14 // Original Author: Sunanda Banerjee
15 // Created: Tue Dec 24 16:40:29 PDT 2013
16 // $Id: HcalDDDRecConstantsESModule.cc,v 1.0 2013/12/24 12:47:41 sunanda Exp $
17 //
18 //
19 
20 // system include files
21 #include <memory>
22 
23 // user include files
27 
32 
33 //#define EDM_ML_DEBUG
34 
36 public:
39 
40  using ReturnType = std::unique_ptr<HcalDDDRecConstants>;
41 
43 
45 
46 private:
49 };
50 
52 #ifdef EDM_ML_DEBUG
53  edm::LogVerbatim("HcalGeom") << "constructing HcalDDDRecConstantsESModule";
54 #endif
55  auto cc = setWhatProduced(this);
58 }
59 
61 
64  descriptions.add("hcalDDDRecConstants", desc);
65 }
66 
67 // ------------ method called to produce the data ------------
69 #ifdef EDM_ML_DEBUG
70  edm::LogVerbatim("HcalGeom") << "in HcalDDDRecConstantsESModule::produce";
71 #endif
72  const auto& par = iRecord.get(parToken_);
73  const auto& hdc = iRecord.get(hdcToken_);
74 
75  return std::make_unique<HcalDDDRecConstants>(&par, hdc);
76 }
77 
78 //define this as a plug-in
edm::ESInputTag
Definition: ESInputTag.h:87
MessageLogger.h
HcalDDDRecConstantsESModule::fillDescriptions
static void fillDescriptions(edm::ConfigurationDescriptions &)
Definition: HcalDDDRecConstantsESMoudle.cc:62
HcalDDDRecConstantsESModule::parToken_
edm::ESGetToken< HcalParameters, HcalParametersRcd > parToken_
Definition: HcalDDDRecConstantsESMoudle.cc:47
edm::ESProducer::setWhatProduced
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition: ESProducer.h:138
HcalDDDRecConstantsESModule::hdcToken_
edm::ESGetToken< HcalDDDSimConstants, HcalSimNumberingRecord > hdcToken_
Definition: HcalDDDRecConstantsESMoudle.cc:48
edm::ParameterSetDescription
Definition: ParameterSetDescription.h:52
ESProducer.h
HcalParameters.h
HcalRecNumberingRecord.h
HcalParametersRcd
Definition: HcalParametersRcd.h:8
HcalDDDSimConstants
Definition: HcalDDDSimConstants.h:24
HcalDDDRecConstantsESModule::produce
ReturnType produce(const HcalRecNumberingRecord &)
Definition: HcalDDDRecConstantsESMoudle.cc:68
edm::ConfigurationDescriptions::add
void add(std::string const &label, ParameterSetDescription const &psetDescription)
Definition: ConfigurationDescriptions.cc:57
edm::eventsetup::DependentRecordImplementation::get
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
Definition: DependentRecordImplementation.h:112
HcalDDDRecConstantsESModule
Definition: HcalDDDRecConstantsESMoudle.cc:35
HcalRecNumberingRecord
Definition: HcalRecNumberingRecord.h:23
edm::ConfigurationDescriptions
Definition: ConfigurationDescriptions.h:28
HcalDDDRecConstantsESModule::HcalDDDRecConstantsESModule
HcalDDDRecConstantsESModule(const edm::ParameterSet &)
Definition: HcalDDDRecConstantsESMoudle.cc:51
edm::ParameterSet
Definition: ParameterSet.h:36
HcalDDDRecConstantsESModule::ReturnType
std::unique_ptr< HcalDDDRecConstants > ReturnType
Definition: HcalDDDRecConstantsESMoudle.cc:40
edm::LogVerbatim
Definition: MessageLogger.h:297
HcalDDDRecConstantsESModule::~HcalDDDRecConstantsESModule
~HcalDDDRecConstantsESModule() override
Definition: HcalDDDRecConstantsESMoudle.cc:60
cc
edm::ESGetToken< HcalParameters, HcalParametersRcd >
ModuleFactory.h
DEFINE_FWK_EVENTSETUP_MODULE
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
Definition: ModuleFactory.h:60
HcalParameters
Definition: HcalParameters.h:6
HcalDDDRecConstants.h
edm::ESProducer
Definition: ESProducer.h:101
HcalSimNumberingRecord
Definition: HcalSimNumberingRecord.h:25
HcalDDDSimConstants.h