CMS 3D CMS Logo

DataMixingHcalDigiWorkerProd.cc
Go to the documentation of this file.
1 // File: DataMixingHcalDigiWorkerProd.cc
2 // Description: see DataMixingHcalDigiWorkerProd.h
3 // Author: Mike Hildreth, University of Notre Dame
4 //
5 //--------------------------------------------
6 
11 
15 
16 using namespace std;
17 namespace edm {
18  // Constructor
19  DataMixingHcalDigiWorkerProd::DataMixingHcalDigiWorkerProd(const edm::ParameterSet &ps,
22  : HBHEPileInputTag_(ps.getParameter<edm::InputTag>("HBHEPileInputTag")),
23  HOPileInputTag_(ps.getParameter<edm::InputTag>("HOPileInputTag")),
24  HFPileInputTag_(ps.getParameter<edm::InputTag>("HFPileInputTag")),
25  ZDCPileInputTag_(ps.getParameter<edm::InputTag>("ZDCPileInputTag")),
26  QIE10PileInputTag_(ps.getParameter<edm::InputTag>("QIE10PileInputTag")),
27  QIE11PileInputTag_(ps.getParameter<edm::InputTag>("QIE11PileInputTag")),
28  tokDB_(tok),
29  label_(ps.getParameter<std::string>("Label")) {
30  //
37 
44 
45  // get the subdetector names
46  // this->getSubdetectorNames(); //something like this may be useful to
47  // check what we are supposed to do...
48 
49  // declare the products to produce
50 
51  // Hcal
52  // Signal inputs now handled by HcalDigitizer - gets pSimHits directly
53 
54  HBHEDigiCollectionDM_ = ps.getParameter<std::string>("HBHEDigiCollectionDM");
55  HODigiCollectionDM_ = ps.getParameter<std::string>("HODigiCollectionDM");
56  HFDigiCollectionDM_ = ps.getParameter<std::string>("HFDigiCollectionDM");
57  ZDCDigiCollectionDM_ = ps.getParameter<std::string>("ZDCDigiCollectionDM");
58  QIE10DigiCollectionDM_ = ps.getParameter<std::string>("QIE10DigiCollectionDM");
59  QIE11DigiCollectionDM_ = ps.getParameter<std::string>("QIE11DigiCollectionDM");
60 
61  // initialize HcalDigitizer here...
62 
63  myHcalDigitizer_ = new HcalDigiProducer(ps, iC);
64 
71  }
72 
73  // Virtual destructor needed.
75 
78  }
79 
82  }
83 
86 
87  } // end of addHcalSignals
88 
90  const EventPrincipal *ep,
91  unsigned int eventNr,
92  const edm::EventSetup &ES,
93  edm::ModuleCallingContext const *mcc) {
94  LogDebug("DataMixingHcalDigiWorkerProd")
95  << "\n===============> adding pileups from event " << ep->id() << " for bunchcrossing " << bcr;
96 
103 
104  // put digis from pileup event into digitizer
105 
111  }
112 
114  // Digitize
115  // edm::Service<edm::RandomNumberGenerator> rng;
116  // CLHEP::HepRandomEngine* engine = &rng->getEngine(e.streamID());
117 
118  // myHcalDigitizer_->initializeEvent( e, ES );
119 
120  // myHcalDigitizer_->finalizeEvent( e, ES, engine );
122  }
123 
124 } // namespace edm
void initializeEvent(const edm::Event *event, const edm::EventSetup *eventSetup, const edm::ESGetToken< HcalDbService, HcalDbRecord > &tok)
const edm::ESGetToken< HcalDbService, HcalDbRecord > tokDB_
void addHcalSignals(const edm::Event &e, const edm::EventSetup &ES)
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
void accumulate(edm::Event const &, edm::EventSetup const &) override
HcalSignalGenerator< HcalQIE10DigitizerTraits > QIE10SignalGenerator
HcalSignalGenerator< HcalQIE11DigitizerTraits > QIE11SignalGenerator
edm::EDGetTokenT< HODigitizerTraits::DigiCollection > tok_ho_
edm::EDGetTokenT< ZDCDigitizerTraits::DigiCollection > tok_zdc_
void setQIE10NoiseSignalGenerator(HcalBaseSignalGenerator *noiseGenerator)
edm::EDGetTokenT< HFDigitizerTraits::DigiCollection > tok_hf_
void setQIE11NoiseSignalGenerator(HcalBaseSignalGenerator *noiseGenerator)
virtual void fill(edm::ModuleCallingContext const *mcc)
void finalizeEvent(edm::Event &, edm::EventSetup const &) override
void initializeEvent(const edm::Event &e, const edm::EventSetup &ES)
edm::EDGetTokenT< HBHEDigitizerTraits::DigiCollection > tok_hbhe_
HcalSignalGenerator< HFDigitizerTraits > HFSignalGenerator
void initializeEvent(edm::Event const &, edm::EventSetup const &) override
void addHcalPileups(const int bcr, const edm::EventPrincipal *, unsigned int EventId, const edm::EventSetup &ES, edm::ModuleCallingContext const *)
void setZDCNoiseSignalGenerator(HcalBaseSignalGenerator *noiseGenerator)
HcalSignalGenerator< HODigitizerTraits > HOSignalGenerator
void putHcal(edm::Event &e, const edm::EventSetup &ES)
HLT enums.
HcalSignalGenerator< ZDCDigitizerTraits > ZDCSignalGenerator
edm::EDGetTokenT< HcalQIE11DigitizerTraits::DigiCollection > tok_qie11_
void beginRun(edm::Run const &, edm::EventSetup const &) override
HcalSignalGenerator< HBHEDigitizerTraits > HBHESignalGenerator
void setHONoiseSignalGenerator(HcalBaseSignalGenerator *noiseGenerator)
void setHFNoiseSignalGenerator(HcalBaseSignalGenerator *noiseGenerator)
void beginRun(const edm::Run &run, const edm::EventSetup &ES)
void setHBHENoiseSignalGenerator(HcalBaseSignalGenerator *noiseGenerator)
edm::EDGetTokenT< HcalQIE10DigitizerTraits::DigiCollection > tok_qie10_
Definition: Run.h:45
#define LogDebug(id)