]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - PHOS/AliPHOSDigit.cxx
Scripts for PHOS alignment
[u/mrichter/AliRoot.git] / PHOS / AliPHOSDigit.cxx
index c11d050ef332bb54419dec39faf0494e0a963294..19bbf04e4613afa30a31bf2a0d75434e8068e062 100644 (file)
 
 /* $Id$ */
 
+/* History of cvs commits:
+ *
+ * $Log$
+ */
+
 //_________________________________________________________________________
 //  PHOS digit: Id
 //              energy
@@ -47,6 +52,8 @@ ClassImp(AliPHOSDigit)
   fIndexInList = -1 ; 
   fNprimary    = 0 ;  
   fPrimary = 0;
+  fTime = 0. ; 
+  fTimeR = 0. ; 
 }
 
 //____________________________________________________________________________
@@ -56,6 +63,7 @@ AliPHOSDigit::AliPHOSDigit(Int_t primary, Int_t id, Int_t digEnergy, Float_t tim
 
   fAmp         = digEnergy ;
   fTime        = time ;
+  fTimeR       = fTime ;
   fId          = id ;
   fIndexInList = index ; 
   if( primary != -1){
@@ -84,6 +92,7 @@ AliPHOSDigit::AliPHOSDigit(const AliPHOSDigit & digit) : AliDigitNew(digit)
     fPrimary = 0 ;
   fAmp         = digit.fAmp ;
   fTime        = digit.fTime ;
+  fTimeR       = digit.fTimeR ;
   fId          = digit.fId;
   fIndexInList = digit.fIndexInList ; 
 }
@@ -132,10 +141,10 @@ Int_t AliPHOSDigit::GetPrimary(Int_t index) const
   
 }
 //____________________________________________________________________________
-void AliPHOSDigit::Print() const
+void AliPHOSDigit::Print(const Option_t *) const
 {
   // Print the digit together with list of primaries
-  printf("PHOS digit: Amp=%d, Id=%d, Time=%f, NPrim=%d ",fAmp,fId,fTime,fNprimary);
+  printf("PHOS digit: Amp=%d, Id=%d, Time=%e, TimeR=%e, NPrim=%d ",fAmp,fId,fTime,fTimeR,fNprimary);
   for(Int_t index = 0; index <fNprimary; index ++ )
     printf(" %d ",fPrimary[index]); 
   printf("\n") ;
@@ -186,6 +195,7 @@ AliPHOSDigit& AliPHOSDigit::operator+(AliPHOSDigit const & digit)
    fAmp += digit.fAmp ;
    if(fTime > digit.fTime)
       fTime = digit.fTime ;
+   fTimeR = fTime ; 
    return *this ;
 }
 //____________________________________________________________________________