]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - EMCAL/AliEMCALDigit.h
SDigits has become a copy of hits and threshold to associate primary particles has...
[u/mrichter/AliRoot.git] / EMCAL / AliEMCALDigit.h
index 439f8e32c5a305d8c77853438a2010d39d40db6c..f93195431a3bbeb777525a0ededf66766f57cfb4 100644 (file)
@@ -6,14 +6,14 @@
 /* $Id$ */
 
 //_________________________________________________________________________
-//  EMCAL digit: Id
-//              energy
-//              3 identifiers for the primary particle(s) at the origine of the digit
-//  The digits are made in FinishEvent() by summing all the hits in a single EMCAL crystal or PPSD gas cell
-//  It would be nice to replace the 3 identifiers by an array, but, because digits are kept in a TClonesQArray,
-//   it is not possible to stream such an array... (beyond my understqnding!)
+//  EMCAL digit: 
+// 
+//  A  Digit is the sum of energy in a Tower (Hit sum) and stores information, about primaries
+//  and enterring particle contributing to a Digit
 //
-//*-- Author: Laurent Aphecetche & Yves Schutz (SUBATECH)
+//*-- Author: Sahal Yacoob (LBL)
+// based on : AliPHOSDigit
+//___________________________________________________________________________
 
 // --- ROOT system ---
 
@@ -22,7 +22,6 @@
 // --- Standard library ---
 
 // --- AliRoot header files ---
-
 #include "AliDigitNew.h"
 
 class AliEMCALDigit : public AliDigitNew {
@@ -32,38 +31,45 @@ class AliEMCALDigit : public AliDigitNew {
  public:
   
   AliEMCALDigit() ;
-  AliEMCALDigit(Int_t primary, Int_t iparent, Int_t id, Int_t DigEnergy, Int_t index = -1) ;
+  AliEMCALDigit(Int_t primary, Int_t iparent, Int_t id, Int_t DigEnergy, Float_t Time, Int_t index = -1) ;
   AliEMCALDigit(const AliEMCALDigit & digit) ;
   virtual ~AliEMCALDigit() ;
 
   Bool_t operator==(const AliEMCALDigit &rValue) const;
   AliEMCALDigit& operator+(AliEMCALDigit const &rValue) ;
-    
+  AliEMCALDigit& AliEMCALDigit::operator*(Float_t factor) ; 
   Int_t   Compare(const TObject * obj) const ;  
+  const Float_t GetEta() const ; 
   Int_t   GetNprimary() const { 
     // returns the number of primaries
     return fNprimary ; }
   Int_t   GetPrimary(Int_t index) const ; 
   Int_t   GetNiparent() const {return fNiparent;}
   Int_t   GetIparent(Int_t index) const ;
+  const Float_t GetPhi() const;
+  Float_t GetTime(void) const {return fTime ;}
+  const Bool_t IsInPreShower() const ;
   Bool_t  IsSortable() const { 
     // says that AliEMCALDigits are sortable (needed for Sort method
     return kTRUE ; }
-  void    SetAmp(Int_t Amp) { 
+  void    SetAmp(Int_t amp) { 
     // sets the amplitude data member 
-    fAmp=Amp ; } 
+    fAmp= amp ; } 
+  void SetId(Int_t id) {fId = id ;}
+  void SetTime(Float_t time) {fTime = time ;}
   void ShiftPrimary(Int_t shift); // shift to semarate different TreeK in merging
-  
- private:
-
+ private: 
   Int_t fNprimary ;     // Number of primaries
-  Int_t fNMaxPrimary ;  //! Max Number of primaries
-  Int_t fPrimary[5] ;   // Array of primaries       
+  Int_t fNMaxPrimary ;  // Max Number of primaries
+  Int_t *fPrimary ;     //[fNMaxPrimary]  Array of primaries       
     
   Int_t fNiparent ;     // Number of initial parents 
-  Int_t fNMaxiparent ;  //! Max Number of parents 
-  Int_t fIparent[50] ;   // Array of parents       
-    
+  Int_t fNMaxiparent ;  // Max Number of parents 
+  Int_t *fIparent ;     //[fNMaxiparent] Array of parents       
+  Float_t fTime ;       // Calculated time  
+
   ClassDef(AliEMCALDigit,1)   // Digit in EMCAL 
 
 } ;