1 #ifndef RecoParticleFlow_PFClusterProducer_PFPSRecHitCreator_h 2 #define RecoParticleFlow_PFClusterProducer_PFPSRecHitCreator_h 34 std::unique_ptr<reco::PFRecHitCollection>& cleaned,
46 for (
const auto& erh : *recHitHandle) {
48 auto energy = erh.energy();
52 switch (detid.plane()) {
61 <<
"incorrect preshower plane !! plane number " << detid.plane() << std::endl;
69 <<
"warning detid " << detid.rawId() <<
" not found in geometry" << std::endl;
74 auto& rh =
out->back();
75 rh.setDepth(detid.plane());
76 rh.setTime(erh.time());
78 bool rcleaned =
false;
84 if (!qtest->test(rh, erh, rcleaned,
hi)) {
void importRecHits(std::unique_ptr< reco::PFRecHitCollection > &out, std::unique_ptr< reco::PFRecHitCollection > &cleaned, const edm::Event &iEvent, const edm::EventSetup &iSetup) override
std::vector< std::unique_ptr< PFRecHitQTestBase > > qualityTests_
Log< level::Error, false > LogError
PFPSRecHitCreator(const edm::ParameterSet &iConfig, edm::ConsumesCollector &cc)
constexpr std::array< uint8_t, layerIndexSize > layer
edm::ESGetToken< CaloGeometry, CaloGeometryRecord > geomToken_
void beginEvent(const edm::Event &event, const edm::EventSetup &setup)
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
virtual std::shared_ptr< const CaloCellGeometry > getGeometry(const DetId &id) const
Get the cell geometry of a given detector id. Should return false if not found.
edm::EDGetTokenT< EcalRecHitCollection > recHitToken_
const CaloSubdetectorGeometry * getSubdetectorGeometry(const DetId &id) const
access the subdetector geometry for the given subdetector directly