CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
SimplePlan1RechitCombiner.h
Go to the documentation of this file.
1 #ifndef RecoLocalCalo_HcalRecAlgos_SimplePlan1RechitCombiner_h_
2 #define RecoLocalCalo_HcalRecAlgos_SimplePlan1RechitCombiner_h_
3 
4 // Base class header
6 
8 public:
10 
11  inline ~SimplePlan1RechitCombiner() override {}
12 
13  void setTopo(const HcalTopology* topo) override;
14  void clear() override;
15  void add(const HBHERecHit& rh) override;
16  void combine(HBHERecHitCollection* toFill) override;
17 
18 protected:
19  // Map the original detector id into the id of the composite rechit
20  virtual HcalDetId mapRechit(HcalDetId from) const;
21 
22  // Return rechit with id of 0 if it is to be discarded
23  virtual HBHERecHit makeRechit(HcalDetId idToMake, const std::vector<const HBHERecHit*>& rechits) const;
24 
25  // Combine rechit auxiliary information
26  virtual void combineAuxInfo(const std::vector<const HBHERecHit*>& rechits, HBHERecHit* rh) const;
27 
29 
30 private:
31  // The first element of the pair is the id of the combined rechit.
32  // The second element is the pointer to the original rechit.
33  typedef std::pair<HcalDetId, const HBHERecHit*> MapItem;
34 
35  std::vector<MapItem> rechitMap_;
36  std::vector<const HBHERecHit*> ptrbuf_;
37 };
38 
39 #endif // RecoLocalCalo_HcalRecAlgos_SimplePlan1RechitCombiner_h_
std::vector< MapItem > rechitMap_
std::vector< const HBHERecHit * > ptrbuf_
virtual void combineAuxInfo(const std::vector< const HBHERecHit * > &rechits, HBHERecHit *rh) const
virtual HBHERecHit makeRechit(HcalDetId idToMake, const std::vector< const HBHERecHit * > &rechits) const
std::pair< HcalDetId, const HBHERecHit * > MapItem
void combine(HBHERecHitCollection *toFill) override
virtual HcalDetId mapRechit(HcalDetId from) const
void add(const HBHERecHit &rh) override
void setTopo(const HcalTopology *topo) override