Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 14:27:51

0001 #ifndef MultiHitGenerator_H
0002 #define MultiHitGenerator_H
0003 
0004 /** abstract interface for generators of hit triplets pairs
0005  *  compatible with a TrackingRegion.
0006  */
0007 
0008 #include "RecoTracker/TkTrackingRegions/interface/OrderedHitsGenerator.h"
0009 #include "RecoTracker/TkSeedingLayers/interface/OrderedMultiHits.h"
0010 
0011 #include "DataFormats/TrackerRecHit2D/interface/BaseTrackerRecHit.h"
0012 #include "DataFormats/TrackingRecHit/interface/mayown_ptr.h"
0013 #include "FWCore/Utilities/interface/RunningAverage.h"
0014 
0015 class TrackingRegion;
0016 namespace edm {
0017   class Event;
0018   class EventSetup;
0019 }  // namespace edm
0020 #include <vector>
0021 
0022 class MultiHitGenerator : public OrderedHitsGenerator {
0023 public:
0024   MultiHitGenerator(unsigned int size = 400) : localRA(size) {}
0025   MultiHitGenerator(MultiHitGenerator const& other) : localRA(other.localRA.mean()) {}
0026 
0027   ~MultiHitGenerator() override {}
0028 
0029   const OrderedMultiHits& run(const TrackingRegion& region, const edm::Event& ev, const edm::EventSetup& es) final;
0030 
0031   // temporary interface, for bckwd compatibility
0032   virtual void hitSets(const TrackingRegion& reg, OrderedMultiHits& prs, const edm::EventSetup& es) {}
0033 
0034   virtual void hitSets(const TrackingRegion& reg,
0035                        OrderedMultiHits& prs,
0036                        const edm::Event& ev,
0037                        const edm::EventSetup& es) = 0;
0038 
0039   void clear() override;
0040 
0041 private:
0042   OrderedMultiHits theHitSets;
0043 
0044 protected:
0045   edm::RunningAverage localRA;
0046 };
0047 
0048 #endif