CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_4_2_9_HLT1_bphpatch4/src/SimG4CMS/Calo/interface/CaloHitID.h

Go to the documentation of this file.
00001 #ifndef SimG4CMS_CaloHitID_H
00002 #define SimG4CMS_CaloHitID_H
00003 
00004 // File: CaloHitID.h
00005 // HitID class for storing unique identifier of a Calorimetric Hit
00007 
00008 #include <boost/cstdint.hpp>
00009 #include <iostream>
00010 
00011 class CaloHitID {
00012 
00013 public:
00014 
00015   CaloHitID(uint32_t unitID, double timeSlice, int trackID, uint16_t depth=0,
00016             int tSlice=1, bool ignoreTkID=false);
00017   CaloHitID(int tSlice=1, bool ignoreTkID=false);
00018   CaloHitID(const CaloHitID&);
00019   const CaloHitID& operator=(const CaloHitID&);
00020   virtual ~CaloHitID();
00021 
00022   uint32_t     unitID()      const {return theUnitID;}
00023   int          timeSliceID() const {return theTimeSliceID;}
00024   double       timeSlice()   const {return theTimeSlice;}
00025   int          trackID()     const {return theTrackID;}
00026   uint16_t     depth()       const {return theDepth;}
00027   void         setID(uint32_t unitID, double timeSlice, int trackID,
00028                      uint16_t depth=0);
00029   void         reset();
00030 
00031   bool operator==(const CaloHitID& ) const;
00032   bool operator<(const CaloHitID& )  const;
00033   bool operator>(const CaloHitID& )  const;
00034  
00035 private:
00036 
00037   uint32_t     theUnitID;
00038   double       theTimeSlice;
00039   int          theTrackID;
00040   int          theTimeSliceID;
00041   uint16_t     theDepth;
00042   int          timeSliceUnit;
00043   bool         ignoreTrackID;
00044 
00045 };
00046 
00047 std::ostream& operator<<(std::ostream&, const CaloHitID&);
00048 #endif