]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - STEER/AliAODCaloCluster.h
Coverity 15850
[u/mrichter/AliRoot.git] / STEER / AliAODCaloCluster.h
index 3ce741aaee6740d9a90ebd18c6a03b4302b6e181..a29e141002290c6d56361b808cc8b4ed328ccb0f 100644 (file)
@@ -16,6 +16,8 @@
 #include <TRefArray.h>
 #include <TArrayS.h>
 
+class TLorentzVector;
+
 class AliAODCaloCluster : public AliAODCluster {
 
  public:
@@ -26,7 +28,7 @@ class AliAODCaloCluster : public AliAODCluster {
                    Int_t *label,
                    Double_t energy,
                    Double_t x[3],
-                   Double_t pid[9],
+                   Double_t pid[13],
                    Char_t ttype=kUndef,
                    UInt_t selectInfo=0);
   
@@ -35,34 +37,34 @@ class AliAODCaloCluster : public AliAODCluster {
                    Int_t *label,
                    Float_t energy,
                    Float_t x[3],
-                   Float_t pid[9],
+                   Float_t pid[13],
                    Char_t ttype=kUndef,
                    UInt_t selectInfo=0);
   
   virtual ~AliAODCaloCluster();
   AliAODCaloCluster(const AliAODCaloCluster& clus); 
   AliAODCaloCluster& operator=(const AliAODCaloCluster& clus);
-
+  void Clear(const Option_t*);
   
   // getters
-  Double_t GetDistToBadChannel() const { return fDistToBadChannel; }
+  Double_t GetDistanceToBadChannel() const { return fDistToBadChannel; }
   Double_t GetDispersion() const { return fDispersion; }
   Double_t GetM20() const { return fM20; }
   Double_t GetM02() const { return fM02; }
-  Double_t GetM11() const { return fM11; }
   Double_t GetEmcCpvDistance() const { return fEmcCpvDistance; }
-  UShort_t GetNExMax() const { return fNExMax; }
+  UChar_t  GetNExMax() const { return fNExMax; }
+  Double_t GetTOF() const { return fTOF; }
 
   Int_t    GetNTracksMatched() const { return fTracksMatched.GetEntriesFast(); }
   TObject *GetTrackMatched(Int_t i) const { return fTracksMatched.At(i); }
  
-  void SetNCells(Int_t n) { fNCells = n;}
-  Double_t GetNCells() const   { return fNCells;}
+  void  SetNCells(Int_t n) { fNCells = n;}
+  Int_t GetNCells() const   { return fNCells;}
   
-  void SetCellsAbsId(UShort_t *array) { fCellsAbsId = array; }
+  void SetCellsAbsId(UShort_t *array);
   UShort_t *GetCellsAbsId() {return  fCellsAbsId;}
   
-  void SetCellsAmplitudeFraction(Double32_t *array) { fCellsAmpFraction = array; }
+  void SetCellsAmplitudeFraction(Double32_t *array);
   Double32_t *GetCellsAmplitudeFraction() {return  fCellsAmpFraction;}
   
   Int_t GetCellAbsId(Int_t i) const {  
@@ -72,32 +74,39 @@ class AliAODCaloCluster : public AliAODCluster {
   Double_t GetCellAmplitudeFraction(Int_t i) const {  
     if (fCellsAmpFraction && i >=0 && i < fNCells ) return fCellsAmpFraction[i];    
     else return -1;}
-
+       
+  //Not defined yet in AODs, put a large number the track is not matched.      
+  Double_t    GetTrackDx(void)const        {return 10000. ;}
+  Double_t    GetTrackDz(void)const        {return 10000. ;}
+       
   // setters
-  void SetDistToBadChannel(Double_t dist) { fDistToBadChannel = dist; }
+  void SetDistanceToBadChannel(Double_t dist) { fDistToBadChannel = dist; }
   void SetDispersion(Double_t disp) { fDispersion = disp; }
   void SetM20(Double_t m20) { fM20 = m20; }
   void SetM02(Double_t m02) { fM02 = m02; }
-  void SetM11(Double_t m11) { fM11 = m11; }
   void SetEmcCpvDistance(Double_t emcCpvDist) { fEmcCpvDistance = emcCpvDist; }
-  void SetNExMax(UShort_t nExMax) { fNExMax = nExMax; }
+  void SetNExMax(UChar_t nExMax) { fNExMax = nExMax; }
+  void SetTOF(Double_t tof) { fTOF = tof; }
+  void SetTrackDistance(Double_t, Double_t ){ ; }
 
   void SetCaloCluster(Double_t dist = -999., 
                      Double_t disp = -1., 
                      Double_t m20 = 0., 
                      Double_t m02 = 0., 
-                     Double_t m11 = 0., 
                      Double_t emcCpvDist = -999., 
-                     UShort_t nExMax = 0) 
+                     UShort_t nExMax = 0, 
+                     Double_t tof = 0.) 
   {
     fDistToBadChannel = dist;
     fDispersion = disp;
     fM20 = m20;
     fM02 = m02;
-    fM11 = m11;
     fEmcCpvDistance = emcCpvDist;
     fNExMax = nExMax;
+    fTOF = tof ;
   }
+  
+  void GetMomentum(TLorentzVector& p, Double_t * vertexPosition );
 
   void AddTrackMatched(TObject *trk) { fTracksMatched.Add(trk); }
   void RemoveTrackMatched(TObject *trk) { fTracksMatched.Remove(trk); }
@@ -109,9 +118,9 @@ class AliAODCaloCluster : public AliAODCluster {
   Double32_t   fDispersion;       // cluster dispersion, for shape analysis
   Double32_t   fM20;              // 2-nd moment along the main eigen axis
   Double32_t   fM02;              // 2-nd moment along the second eigen axis
-  Double32_t   fM11;              // 2-nd mixed moment Mxy
   Double32_t   fEmcCpvDistance;   // the distance from PHOS EMC rec.point to the closest CPV rec.point
   UShort_t     fNExMax;           // number of (Ex-)maxima before unfolding
+  Double32_t   fTOF;              ////[0,0,12] time-of-flight
 
   TRefArray    fTracksMatched;    // references to tracks close to cluster. First entry is the most likely match.
 
@@ -119,7 +128,7 @@ class AliAODCaloCluster : public AliAODCluster {
   UShort_t   *fCellsAbsId;        //[fNCells] array of cell absId numbers
   Double32_t *fCellsAmpFraction;  //[fNCells][0.,1.,16] array with cell amplitudes fraction.
 
-  ClassDef(AliAODCaloCluster,3);
+  ClassDef(AliAODCaloCluster,6);
 };
 
 #endif