CMS 3D CMS Logo

PixelFitterByConformalMappingAndLineProducer.cc
Go to the documentation of this file.
3 
8 
12 
15 
20 
22 public:
24  : theTTRHBuilderName(iConfig.getParameter<std::string>("TTRHBuilder")),
27  if (iConfig.getParameter<bool>("useFixImpactParameter")) {
28  theFixImpactParameter = iConfig.getParameter<double>("fixImpactParameter");
30  }
31 
32  produces<PixelFitter>();
33  }
35 
36  static void fillDescriptions(edm::ConfigurationDescriptions& descriptions) {
38 
39  desc.add<std::string>("TTRHBuilder", "PixelTTRHBuilderWithoutAngle");
40  desc.add<bool>("useFixImpactParameter", false);
41  desc.add<double>("fixImpactParameter", 0.0);
42  descriptions.add("pixelFitterByConformalMappingAndLine", desc);
43  }
44 
45 private:
46  void produce(edm::StreamID, edm::Event& iEvent, const edm::EventSetup& iSetup) const override;
47 
51 };
52 
55  const edm::EventSetup& iSetup) const {
57  iSetup.get<TransientRecHitRecord>().get(theTTRHBuilderName, ttrhBuilder);
58 
60  iSetup.get<TrackerDigiGeometryRecord>().get(tracker);
61 
63  iSetup.get<IdealMagneticFieldRecord>().get(field);
64 
65  auto impl = std::make_unique<PixelFitterByConformalMappingAndLine>(
66  ttrhBuilder.product(), tracker.product(), field.product(), theFixImpactParameter, theUseFixImpactParameter);
67  auto prod = std::make_unique<PixelFitter>(std::move(impl));
68  iEvent.put(std::move(prod));
69 }
70 
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
Definition: Event.h:131
int iEvent
Definition: GenABIO.cc:224
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
ParameterDescriptionBase * add(U const &iLabel, T const &value)
void produce(edm::StreamID, edm::Event &iEvent, const edm::EventSetup &iSetup) const override
void add(std::string const &label, ParameterSetDescription const &psetDescription)
T get() const
Definition: EventSetup.h:73
T const * product() const
Definition: ESHandle.h:86
def move(src, dest)
Definition: eostools.py:511