CMS 3D CMS Logo

SiTrackerMultiRecHitUpdatorESProducer.cc
Go to the documentation of this file.
4 
9 
10 #include <string>
11 #include <memory>
12 
13 using namespace edm;
14 
16  std::string myname = p.getParameter<std::string>("ComponentName");
17  pset_ = p;
18  setWhatProduced(this, myname);
19 }
20 
22 
23 std::unique_ptr<SiTrackerMultiRecHitUpdator> SiTrackerMultiRecHitUpdatorESProducer::produce(
24  const MultiRecHitRecord& iRecord) {
25  std::vector<double> annealingProgram = pset_.getParameter<std::vector<double> >("AnnealingProgram");
26  float Chi2Cut1D = pset_.getParameter<double>("ChiSquareCut1D");
27  float Chi2Cut2D = pset_.getParameter<double>("ChiSquareCut2D");
28 
30  std::string sname = pset_.getParameter<std::string>("TTRHBuilder");
31  iRecord.getRecord<TransientRecHitRecord>().get(sname, hbuilder);
32  std::string hitpropagator = pset_.getParameter<std::string>("HitPropagator");
34  iRecord.getRecord<CkfComponentsRecord>().getRecord<TrackingComponentsRecord>().get(hitpropagator, hhitpropagator);
35 
36  bool debug = pset_.getParameter<bool>("Debug");
37  //_updator = std::make_unique<SiTrackerMultiRecHitUpdator>(pDD.product(), pp, sp, mp, annealingProgram);
38  // _updator = std::make_unique<SiTrackerMultiRecHitUpdator>(hhitpropagator.product(),annealingProgram);
39  return std::make_unique<SiTrackerMultiRecHitUpdator>(
40  hbuilder.product(), hhitpropagator.product(), Chi2Cut1D, Chi2Cut2D, annealingProgram, debug);
41 }
T getParameter(std::string const &) const
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
#define debug
Definition: HDRShower.cc:19
HLT enums.
std::unique_ptr< SiTrackerMultiRecHitUpdator > produce(const MultiRecHitRecord &)