Back to home page

sPhenix code displayed by LXR

 
 

    


File indexing completed on 2025-12-16 09:20:35

0001 /**
0002  * @file trackbase/TrkrClusterHitAssocv2.h
0003  * @author D. McGlinchey
0004  * @date June 2018
0005  * @brief Version 1 of class for associating clusters to the hits that went into them
0006  */
0007 #ifndef TRACKBASE_TRKRCLUSTERHITASSOCV2_H
0008 #define TRACKBASE_TRKRCLUSTERHITASSOCV2_H
0009 
0010 #include "TrkrClusterHitAssoc.h"
0011 #include "TrkrDefs.h"
0012 
0013 #include <phool/PHObject.h>
0014 
0015 #include <iostream>  // for cout, ostream
0016 #include <map>
0017 #include <utility>  // for pair
0018 
0019 /**
0020  * @brief Class for associating clusters to the hits that went into them
0021  *
0022  * Store the associations between clusters and the hits that went into them.
0023  */
0024 class TrkrClusterHitAssocv2 : public TrkrClusterHitAssoc
0025 {
0026  public:
0027   TrkrClusterHitAssocv2() = default;
0028 
0029   void Reset() override;
0030 
0031   void identify(std::ostream& os = std::cout) const override;
0032 
0033   void addAssoc(TrkrDefs::cluskey, unsigned int) override;
0034 
0035   Map* getClusterMap(TrkrDefs::hitsetkey) override;
0036 
0037   ConstRange getHits(TrkrDefs::cluskey) override;
0038 
0039   unsigned int size() const override;
0040 
0041  private:
0042   unsigned int max_layer = 57;
0043   unsigned int max_phisegment = 12;
0044   unsigned int max_zsegment = 8;
0045   Map m_map[57][12][8];
0046 
0047   ClassDefOverride(TrkrClusterHitAssocv2, 1);
0048 };
0049 
0050 #endif  // TRACKBASE_TRKRCLUSTERHITASSOC_H