46 ftlbInstance_(ps.getParameter<
std::
string>(
"BarrelHitsName")),
47 ftleInstance_(ps.getParameter<
std::
string>(
"EndcapHitsName")) {
51 auto sumes = consumesCollector();
52 mtdgeoToken_ = esConsumes<MTDGeometry, MTDDigiGeometryRecord>();
77 auto barrelRechits = std::make_unique<FTLRecHitCollection>();
78 auto endcapRechits = std::make_unique<FTLRecHitCollection>();
82 if (hBarrel.isValid()) {
83 barrelRechits->reserve(hBarrel->size() / 2);
84 for (
const auto& uhit : *hBarrel) {
88 barrelRechits->push_back(rechit);
91 edm::LogWarning(
"MTDReco") <<
"MTDRecHitProducer: Missing Uncalibrated Barrel RecHit Collection";
97 endcapRechits->reserve(hEndcap->
size() / 2);
98 for (
const auto& uhit : *hEndcap) {
102 endcapRechits->push_back(rechit);
105 edm::LogWarning(
"MTDReco") <<
"MTDRecHitProducer: Missing Uncalibrated Endcap RecHit Collection";
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
~MTDRecHitProducer() override
ParameterSet const & getParameterSet(std::string const &) const
MTDRecHitProducer(const edm::ParameterSet &ps)
bool getByToken(EDGetToken token, Handle< PROD > &result) const
std::unique_ptr< MTDRecHitAlgoBase > endcap_
const edm::EDGetTokenT< FTLUncalibratedRecHitCollection > ftleURecHits_
const MTDGeometry * geom_
#define DEFINE_FWK_MODULE(type)
const std::string ftleInstance_
edm::ESGetToken< MTDGeometry, MTDDigiGeometryRecord > mtdgeoToken_
const std::string ftlbInstance_
void produce(edm::Event &evt, const edm::EventSetup &es) override
ESTransientHandle< T > getTransientHandle(const ESGetToken< T, R > &iToken) const
std::unique_ptr< MTDRecHitAlgoBase > barrel_
Log< level::Warning, false > LogWarning
const edm::EDGetTokenT< FTLUncalibratedRecHitCollection > ftlbURecHits_