CMS 3D CMS Logo

L1TCaloConfigESProducer.cc
Go to the documentation of this file.
1 
10 // system include files
11 #include <memory>
12 #include <iostream>
13 #include <fstream>
14 
15 // user include files
21 
23 
27 
28 using namespace std;
29 
30 //
31 // class declaration
32 //
33 
34 using namespace l1t;
35 
37 public:
39  ~L1TCaloConfigESProducer() override;
40 
41  using ReturnType = std::unique_ptr<CaloConfig>;
42 
43  ReturnType produce(const L1TCaloConfigRcd&);
44 
45 private:
48 };
49 
50 //
51 // constants, enums and typedefs
52 //
53 
54 //
55 // static data member definitions
56 //
57 
58 //
59 // constructors and destructor
60 //
62  //the following line is needed to tell the framework what
63  // data is being produced
64  setWhatProduced(this);
65  //setWhatProduced(this, conf.getParameter<std::string>("label"));
66 
67  std::string l1epoch = conf.getParameter<string>("l1Epoch");
68  unsigned fwv = conf.getParameter<unsigned>("fwVersionLayer2");
69  CaloConfigHelper h(m_params, fwv, l1epoch);
70 }
71 
73  // do anything here that needs to be done at desctruction time
74  // (e.g. close files, deallocate resources etc.)
75 }
76 
77 //
78 // member functions
79 //
80 
81 // ------------ method called to produce the data ------------
83  return std::make_unique<CaloConfig>(m_params);
84 }
85 
86 //define this as a plug-in
MessageLogger.h
ESHandle.h
h
FWCore Framework interface EventSetupRecordImplementation h
Helper function to determine trigger accepts.
Definition: L1TUtmAlgorithmRcd.h:4
ESProducer.h
L1TCaloConfigESProducer::m_label
std::string m_label
Definition: L1TCaloConfigESProducer.cc:47
l1t::CaloConfig
Definition: CaloConfig.h:24
FileInPath.h
L1TCaloConfigESProducer::ReturnType
std::unique_ptr< CaloConfig > ReturnType
Definition: L1TCaloConfigESProducer.cc:41
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
ESProducts.h
edm::ParameterSet
Definition: ParameterSet.h:36
l1t
delete x;
Definition: CaloConfig.h:22
L1TCaloConfigESProducer::~L1TCaloConfigESProducer
~L1TCaloConfigESProducer() override
Definition: L1TCaloConfigESProducer.cc:72
l1t::CaloConfigHelper
Definition: CaloConfigHelper.h:12
L1TCaloConfigESProducer::produce
ReturnType produce(const L1TCaloConfigRcd &)
Definition: L1TCaloConfigESProducer.cc:82
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
ModuleFactory.h
std
Definition: JetResolutionObject.h:76
L1TCaloConfigESProducer::L1TCaloConfigESProducer
L1TCaloConfigESProducer(const edm::ParameterSet &)
Definition: L1TCaloConfigESProducer.cc:61
DEFINE_FWK_EVENTSETUP_MODULE
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
Definition: ModuleFactory.h:60
edm::ESProducer
Definition: ESProducer.h:101
L1TCaloConfigESProducer
Definition: L1TCaloConfigESProducer.cc:36
CaloConfig.h
L1TCaloConfigESProducer::m_params
CaloConfig m_params
Definition: L1TCaloConfigESProducer.cc:46
L1TCaloConfigRcd.h
L1TCaloConfigRcd
Definition: L1TCaloConfigRcd.h:16
CaloConfigHelper.h