CMS 3D CMS Logo

TSCBLBuilderWithPropagatorESProducer.cc
Go to the documentation of this file.
1 //
2 // Original Author: Matt Rudolph
3 // Created: Sat Mar 28 20:13:08 CET 2009
4 //
5 //
6 
7 // system include files
8 #include <memory>
9 
10 // user include files
14 
18 
19 //
20 // class decleration
21 //
22 
24 public:
27 
28  typedef std::unique_ptr<TrajectoryStateClosestToBeamLineBuilder> ReturnType;
29 
31 
32 private:
33  // ----------member data ---------------------------
35 };
36 
37 //
38 // constants, enums and typedefs
39 //
40 
41 //
42 // static data member definitions
43 //
44 
45 //
46 // constructors and destructor
47 //
49  //the following line is needed to tell the framework what
50  // data is being produced
51  std::string myName = p.getParameter<std::string>("ComponentName");
52  pset_ = p;
53  setWhatProduced(this, myName);
54 
55  //now do what ever other initialization is needed
56 }
57 
59  // do anything here that needs to be done at desctruction time
60  // (e.g. close files, deallocate resources etc.)
61 }
62 
63 //
64 // member functions
65 //
66 
67 // ------------ method called to produce the data ------------
69  const TrackingComponentsRecord& iRecord) {
70  using namespace edm::es;
71  std::string propname = pset_.getParameter<std::string>("Propagator");
72 
74  iRecord.get(propname, theProp);
75 
76  const Propagator* pro = theProp.product();
77 
78  auto pTSCBLBuilderWithPropagator = std::make_unique<TSCBLBuilderWithPropagator>(*pro);
79 
80  return pTSCBLBuilderWithPropagator;
81 }
82 
83 //define this as a plug-in
ESHandle.h
TSCBLBuilderWithPropagatorESProducer::ReturnType
std::unique_ptr< TrajectoryStateClosestToBeamLineBuilder > ReturnType
Definition: TSCBLBuilderWithPropagatorESProducer.cc:28
edm::ESProducer::setWhatProduced
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition: ESProducer.h:163
TSCBLBuilderWithPropagatorESProducer::TSCBLBuilderWithPropagatorESProducer
TSCBLBuilderWithPropagatorESProducer(const edm::ParameterSet &)
Definition: TSCBLBuilderWithPropagatorESProducer.cc:48
ESProducer.h
Propagator
Definition: Propagator.h:44
TrajectoryStateClosestToBeamLineBuilder.h
edm::ESHandle< Propagator >
edm::eventsetup::DependentRecordImplementation::get
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
Definition: DependentRecordImplementation.h:109
edm::ParameterSet
Definition: ParameterSet.h:47
AlCaHLTBitMon_ParallelJobs.p
def p
Definition: AlCaHLTBitMon_ParallelJobs.py:153
TSCBLBuilderWithPropagator.h
TSCBLBuilderWithPropagatorESProducer
Definition: TSCBLBuilderWithPropagatorESProducer.cc:23
TSCBLBuilderWithPropagatorESProducer::~TSCBLBuilderWithPropagatorESProducer
~TSCBLBuilderWithPropagatorESProducer() override
Definition: TSCBLBuilderWithPropagatorESProducer.cc:58
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
ModuleFactory.h
TSCBLBuilderWithPropagatorESProducer::produce
ReturnType produce(const TrackingComponentsRecord &)
Definition: TSCBLBuilderWithPropagatorESProducer.cc:68
DEFINE_FWK_EVENTSETUP_MODULE
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
Definition: ModuleFactory.h:60
TSCBLBuilderWithPropagatorESProducer::pset_
edm::ParameterSet pset_
Definition: TSCBLBuilderWithPropagatorESProducer.cc:34
TrackingComponentsRecord.h
edm::es
Definition: es_Label.h:33
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
edm::ESProducer
Definition: ESProducer.h:104
TrackingComponentsRecord
Definition: TrackingComponentsRecord.h:12