File indexing completed on 2023-03-17 11:25:41
0001 #ifndef SimTracker_SiStripDigitizer_DigiSimLinkPileUpSignals_h
0002 #define SimTracker_SiStripDigitizer_DigiSimLinkPileUpSignals_h
0003
0004 #include <map>
0005 #include <vector>
0006 #include "SimDataFormats/TrackingHit/interface/PSimHit.h"
0007
0008 class SimHit;
0009
0010
0011
0012
0013 class DigiSimLinkPileUpSignals {
0014 public:
0015
0016 typedef float Amplitude;
0017
0018
0019 typedef std::map<int, std::vector<std::pair<const PSimHit*, Amplitude> >, std::less<int> > HitToDigisMapType;
0020
0021
0022 typedef std::map<int, std::vector<std::pair<const PSimHit*, int> >, std::less<int> > HitCounterToDigisMapType;
0023
0024 DigiSimLinkPileUpSignals() { reset(); }
0025
0026 virtual ~DigiSimLinkPileUpSignals() {}
0027
0028 virtual void add(const std::vector<float>& locAmpl,
0029 const size_t& firstChannelWithSignal,
0030 const size_t& lastChannelWithSignal,
0031 const PSimHit* hit,
0032 const int& counter);
0033
0034 void reset() { resetLink(); }
0035
0036 const HitToDigisMapType& dumpLink() const { return theMapLink; }
0037
0038 const HitCounterToDigisMapType& dumpCounterLink() const { return theCounterMapLink; }
0039
0040 private:
0041 void resetLink();
0042 HitToDigisMapType theMapLink;
0043 HitCounterToDigisMapType theCounterMapLink;
0044 };
0045 #endif