Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-06-05 08:56:54

0001 #ifndef EDM4HEP_UTILS_TRACKUTILS_H
0002 #define EDM4HEP_UTILS_TRACKUTILS_H
0003 
0004 #include <edm4hep/RecDqdxCollection.h>
0005 #include <edm4hep/Track.h>
0006 
0007 #include <map>
0008 #include <vector>
0009 
0010 namespace edm4hep::utils {
0011 /// Utility class to invert the relations between RecDqdx to Track relation
0012 class TrackPIDHandler {
0013   using TrackMapT = std::multimap<edm4hep::Track, edm4hep::RecDqdx>;
0014 
0015   TrackMapT m_trackDqMap{}; ///< The internal map from tracks to RecDqdx
0016 public:
0017   /// Add the information from the passed collection to the handler
0018   void addColl(const edm4hep::RecDqdxCollection& coll);
0019 
0020   /// Get all RecDqdx objects for the given track
0021   std::vector<edm4hep::RecDqdx> getDqdxValues(const edm4hep::Track& track) const;
0022 };
0023 } // namespace edm4hep::utils
0024 
0025 #endif // EDM4HEP_UTILS_TRACKUTILS_H