CMS 3D CMS Logo

TrackFitterProducer.cc
Go to the documentation of this file.
3 
8 
12 
15 
22 
24 public:
25  explicit TrackFitterProducer(const edm::ParameterSet& iConfig);
27 
28  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
29 
30 private:
31  virtual void produce(edm::StreamID, edm::Event& iEvent, const edm::EventSetup& iSetup) const override;
32 
35 };
36 
38  theTTRHBuilderName(iConfig.getParameter<std::string>("TTRHBuilder"))
39 {
40  produces<PixelFitter>();
41 }
42 
45 
46  desc.add<std::string>("TTRHBuilder", "");
47 
48  descriptions.add("trackFitter", desc);
49 }
50 
53  iSetup.get<TrackerDigiGeometryRecord>().get(trackerESH);
54 
56  iSetup.get<IdealMagneticFieldRecord>().get(fieldESH);
57 
59  iSetup.get<TransientRecHitRecord>().get(theTTRHBuilderName, ttrhbESH);
60 
61  auto impl = std::make_unique<TrackFitter>(&iSetup,
62  trackerESH.product(),
63  fieldESH.product(),
64  ttrhbESH.product());
65  auto prod = std::make_unique<PixelFitter>(std::move(impl));
66  iEvent.put(std::move(prod));
67 }
68 
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
Definition: Event.h:122
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:17
edm::EDGetTokenT< reco::BeamSpot > theBeamSpotToken
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
int iEvent
Definition: GenABIO.cc:230
ParameterDescriptionBase * add(U const &iLabel, T const &value)
const T & get() const
Definition: EventSetup.h:55
void add(std::string const &label, ParameterSetDescription const &psetDescription)
virtual void produce(edm::StreamID, edm::Event &iEvent, const edm::EventSetup &iSetup) const override
T const * product() const
Definition: ESHandle.h:86
TrackFitterProducer(const edm::ParameterSet &iConfig)
def move(src, dest)
Definition: eostools.py:510