CMS 3D CMS Logo

Mixing2DB.cc
Go to the documentation of this file.
1 #include "Mixing2DB.h"
5 
7 
8 //
9 // constants, enums and typedefs
10 //
11 
12 //
13 // static data member definitions
14 //
15 
16 //
17 // constructors and destructor
18 //
20  //cfi_=iConfig.getParameter<edm::ParameterSet>("input");
21  cfi_ = iConfig;
22 }
23 
25  // do anything here that needs to be done at desctruction time
26  // (e.g. close files, deallocate resources etc.)
27 }
28 
29 //
30 // member functions
31 //
32 
33 // ------------ method called for each event ------------
34 void Mixing2DB::analyze(const edm::Event& iEvent, const edm::EventSetup& iSetup) {
35  using namespace edm;
36 
37 #ifdef THIS_IS_AN_EVENT_EXAMPLE
39  iEvent.getByLabel("example", pIn);
40 #endif
41 
42 #ifdef THIS_IS_AN_EVENTSETUP_EXAMPLE
43  ESHandle<SetupData> pSetup;
44  iSetup.get<SetupRecord>().get(pSetup);
45 #endif
46 }
47 
48 // ------------ method called once each job just before starting event loop ------------
50 
51 // ------------ method fills 'descriptions' with the allowed parameters for the module ------------
53  //The following says we do not know what parameters are allowed so do no validation
54  // Please change this to state exactly what you do use, even if it is no parameters
56  desc.setUnknown();
57  descriptions.addDefault(desc);
58 }
59 
60 // ------------ method called once each job just after ending the event loop ------------
64  config->read(cfi_);
65  poolDbService->writeOne<MixingModuleConfig>(config, poolDbService->currentTime(), "MixingRcd");
66 }
edm::ParameterSet cfi_
Definition: Mixing2DB.h:49
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
Definition: Mixing2DB.cc:52
void endJob() override
Definition: Mixing2DB.cc:61
Definition: config.py:1
config
Definition: looper.py:291
int iEvent
Definition: GenABIO.cc:224
void addDefault(ParameterSetDescription const &psetDescription)
~Mixing2DB() override
Definition: Mixing2DB.cc:24
void analyze(const edm::Event &, const edm::EventSetup &) override
Definition: Mixing2DB.cc:34
void writeOne(T *payload, Time_t time, const std::string &recordName, bool withlogging=false)
Mixing2DB(const edm::ParameterSet &)
Definition: Mixing2DB.cc:19
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
Definition: Event.h:488
void beginJob() override
Definition: Mixing2DB.cc:49
HLT enums.
T get() const
Definition: EventSetup.h:73
void read(edm::ParameterSet &pset)