#include <PropagatorWithMaterialESProducer.h>
Public Member Functions | |
boost::shared_ptr< Propagator > | produce (const TrackingComponentsRecord &) |
PropagatorWithMaterialESProducer (const edm::ParameterSet &p) | |
virtual | ~PropagatorWithMaterialESProducer () |
Private Attributes | |
boost::shared_ptr< Propagator > | _propagator |
edm::ParameterSet | pset_ |
ESProducer for PropagatorWithMaterial.
Definition at line 18 of file PropagatorWithMaterialESProducer.h.
PropagatorWithMaterialESProducer::PropagatorWithMaterialESProducer | ( | const edm::ParameterSet & | p | ) |
Definition at line 16 of file PropagatorWithMaterialESProducer.cc.
References edm::ParameterSet::getParameter(), AlCaHLTBitMon_ParallelJobs::p, and AlCaHLTBitMon_QueryRunRegistry::string.
{ std::string myname = p.getParameter<std::string>("ComponentName"); pset_ = p; setWhatProduced(this,myname); }
PropagatorWithMaterialESProducer::~PropagatorWithMaterialESProducer | ( | ) | [virtual] |
Definition at line 23 of file PropagatorWithMaterialESProducer.cc.
{}
boost::shared_ptr< Propagator > PropagatorWithMaterialESProducer::produce | ( | const TrackingComponentsRecord & | iRecord | ) |
Definition at line 26 of file PropagatorWithMaterialESProducer.cc.
References alongMomentum, anyDirection, dir, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::getRecord(), HLT_ES_cff::magfield, oppositeToMomentum, PtMinSelector_cfg::ptMin, and AlCaHLTBitMon_QueryRunRegistry::string.
{ // if (_propagator){ // delete _propagator; // _propagator = 0; // } ESHandle<MagneticField> magfield; iRecord.getRecord<IdealMagneticFieldRecord>().get(magfield ); std::string pdir = pset_.getParameter<std::string>("PropagationDirection"); double mass = pset_.getParameter<double>("Mass"); double maxDPhi = pset_.getParameter<double>("MaxDPhi"); bool useRK = pset_.getParameter<bool>("useRungeKutta"); bool useOldAnalPropLogic = pset_.existsAs<bool>("useOldAnalPropLogic") ? pset_.getParameter<bool>("useOldAnalPropLogic") : true; double ptMin = pset_.existsAs<double>("ptMin") ? pset_.getParameter<double>("ptMin") : -1.0; PropagationDirection dir = alongMomentum; if (pdir == "oppositeToMomentum") dir = oppositeToMomentum; if (pdir == "alongMomentum") dir = alongMomentum; if (pdir == "anyDirection") dir = anyDirection; _propagator = boost::shared_ptr<Propagator>(new PropagatorWithMaterial(dir, mass, &(*magfield), maxDPhi,useRK,ptMin, useOldAnalPropLogic)); return _propagator; }
boost::shared_ptr<Propagator> PropagatorWithMaterialESProducer::_propagator [private] |
Definition at line 24 of file PropagatorWithMaterialESProducer.h.
Definition at line 25 of file PropagatorWithMaterialESProducer.h.