]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - PHOS/AliPHOSDigitizer.h
Partial redesign of identification bits and coding rule corrections
[u/mrichter/AliRoot.git] / PHOS / AliPHOSDigitizer.h
index e96a222dfd0bf68ed086ea821e3cdcaf7725afdd..a48108294315c27b34da85a3fdb134b405b85a89 100644 (file)
@@ -18,6 +18,7 @@
 #include "TObjString.h"
 class TArrayI ;
 class TClonesArray ; 
+class TFile ; 
 
 // --- Standard library ---
 
@@ -30,7 +31,7 @@ class AliPHOSDigitizer: public AliDigitizer {
 
 public:
   AliPHOSDigitizer() ;          // ctor
-  AliPHOSDigitizer(const char *headerFile, const char * name = "Default") ; 
+  AliPHOSDigitizer(const char *headerFile, const char * name = "Default", const Bool_t toSplit = kFALSE ) ; 
   AliPHOSDigitizer(AliRunDigitizer * ard) ;
   AliPHOSDigitizer(const AliPHOSDigitizer & dtizer) 
                   {( (AliPHOSDigitizer &)dtizer ).Copy(*this) ;} 
@@ -64,19 +65,16 @@ public:
   void   SetNEMCchannels(Int_t n)      { fNADCemc = n; }
   void   SetEMCchannel(Float_t width)  { fADCchanelEmc = width; }
   void   SetEMCpedestal(Float_t ped)   { fADCpedestalEmc = ped ; }  
+  void   SetTimeResolution(Float_t res){ fTimeResolution = res ; }  
 
   //General
   const Int_t   GetDigitsInRun()  const { return fDigitsInRun ;}  
-
-  void    MixWith(const char* HeaderFile) ; // Add another one file to mix
+  void    MixWith(const char* HeaderFile,const char* brname = 0) ; // Add another one file to mix
   void    Print(Option_t* option)const ;
-  void    Reset() ;   //restarts starts event processing from 0 event(s)
-  void    SetSplitFile(const TString splitFileName = "PHOS.Digits.root") ;
-  void    SetSDigitsBranch(const char* file) ;
-
   AliPHOSDigitizer & operator = (const AliPHOSDigitizer & rvalue)  {
     // assignement operator requested by coding convention but not needed
-    abort() ;
+    Fatal("operator =", "not implemented") ;
     return *this ; 
   }
 
@@ -86,14 +84,17 @@ private:
   void    InitParameters() ; 
   void    PrintDigits(Option_t * option) ;
   void    WriteDigits(Int_t evt) ;            // Writes Digits for particular event
-  Float_t TimeOfNoise(void) ;                 // Calculate time signal generated by noise
+  Float_t TimeOfNoise(void) const;            // Calculate time signal generated by noise
   //Calculate the time of crossing of the threshold by front edge
-  Float_t FrontEdgeTime(TClonesArray * ticks) ; 
+  Float_t FrontEdgeTime(TClonesArray * ticks) const 
   //Calculate digitized signal with gived ADC parameters
   Int_t   DigitizeEnergy(Float_t energy, Int_t absId) ;
 
 private:
 
+  Bool_t  fDefaultInit;             //! Says if the task was created by defaut ctor (only parameters are initialized)
+  Int_t fDigitsInRun ;              //! Total number of digits in one run
+
   Int_t   fEmcCrystals ;            // Number of EMC crystalls in the given geometry
 
   Float_t fPinNoise ;               // Electronics noise in EMC
@@ -102,20 +103,21 @@ private:
   Float_t fCPVNoise ;               // Noise in CPV
   Float_t fCPVDigitThreshold  ;     // Threshold for storing digits in CPV
 
-  Int_t fDigitsInRun ;              //! Total number of digits in one run
 
   Float_t fTimeResolution ;         // Time resolution of FEE electronics
   Float_t fTimeThreshold ;          // Threshold to start timing for given crystall
   Float_t fTimeSignalLength ;       // Length of the timing signal 
 
   Float_t fADCchanelEmc ;           // width of one ADC channel in GeV
-  Float_t fADCpedestalEmc ;         //
+  Float_t fADCpedestalEmc ;         // value of the EMC ADC pedestal
   Int_t   fNADCemc ;                // number of channels in EMC ADC
 
-  Float_t fADCchanelCpv ;           // width of one ADC channel in CPV 'popugais'
-  Float_t fADCpedestalCpv ;         // 
+  Float_t fADCchanelCpv ;           // width of one ADC channel in CPV units
+  Float_t fADCpedestalCpv ;         // value of the CPV ADC pedestal in CPV units
   Int_t   fNADCcpv ;                // number of channels in CPV ADC
-  TFile * fSplitFile ;             //! file in which Digits will eventually be stored
+
+  Bool_t  fToSplit ;                //! Do we work in the split mode
+  TFile * fSplitFile ;              //! file in which Digits will eventually be stored
 
 
   ClassDef(AliPHOSDigitizer,1)  // description