]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PHOS/AliPHOSDigitizer.h
Default branch name set to Default, consistence with AliDigitizer added: new ctr...
[u/mrichter/AliRoot.git] / PHOS / AliPHOSDigitizer.h
1 #ifndef ALIPHOSDigitizer_H
2 #define ALIPHOSDigitizer_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice                               */
5
6 /* $Id$ */
7
8 //_________________________________________________________________________
9 //  Task Class for making SDigits in PHOS      
10 // Class performs digitization of Summable digits (in the PHOS case this is just
11 // sum of contributions of all primary particles into given cell). 
12 // In addition it performs mixing of summable digits from different events.
13 //                  
14 //*-- Author: Dmitri Peressounko(SUBATECH & KI)
15
16
17 // --- ROOT system ---
18 #include "TTask.h"
19 #include "TObjString.h"
20 class TArrayI ;
21 // --- Standard library ---
22
23 // --- AliRoot header files ---
24 #include "AliDigitizer.h"
25 class AliPHOSSDigitizer ;
26 class AliRunDigitizer ;
27
28 class AliPHOSDigitizer: public TTask {
29
30 public:
31   AliPHOSDigitizer() ;          // ctor
32   AliPHOSDigitizer(const char *headerFile, const char * name = "Default") ; 
33   AliPHOSDigitizer(AliRunDigitizer * ard) ;
34   AliPHOSDigitizer(const AliPHOSDigitizer & dtizer) 
35                   {( (AliPHOSDigitizer &)dtizer ).Copy(*this) ;} 
36   virtual ~AliPHOSDigitizer() ;       
37
38   void    Digitize(const Int_t event) ;            // Make Digits from SDigits 
39   void    Exec(Option_t *option);                // Supervising method
40
41   const Float_t GetCPVNoise()     const { return fCPVNoise ;}
42   const Float_t GetCPVThreshold() const { return fCPVDigitThreshold ;}
43   const Int_t   GetDigitsInRun()  const { return fDigitsInRun ;}  
44   const Float_t GetEMCThreshold() const { return fEMCDigitThreshold;}
45   const Float_t GetPedestal()     const { return fPedestal; }
46   const Float_t GetPinNoise()     const { return fPinNoise;}
47   const Float_t GetPPSDNoise()    const { return fPPSDNoise ;}
48   const Float_t GetPPSDThreshold()const { return fPPSDDigitThreshold ;}
49   const Float_t GetSlope()        const { return fSlope; }
50   //  const TArrayI      * GetCurrentEvents()const { return fIevent ;}
51
52   void    MixWith(const char* HeaderFile) ; // Add another one file to mix
53   void    Print(Option_t* option)const ;
54   void    Reset() ;   //restarts starts event processing from 0 event(s)
55
56   void    SetCPVNoise(Float_t CPVNoise)          {fCPVNoise = CPVNoise;}
57   void    SetCPVThreshold(Float_t CPVThreshold)  {fCPVDigitThreshold= CPVThreshold;}
58   void    SetEMCThreshold(Float_t EMCThreshold)  {fEMCDigitThreshold = EMCThreshold;}
59   void    SetPinNoise(Float_t PinNoise )         {fPinNoise = PinNoise;}
60   void    SetPPSDNoise(Float_t PPSDNoise)        {fPPSDNoise = PPSDNoise;}
61   void    SetPPSDThreshold(Float_t PPSDThreshold){fPPSDDigitThreshold = PPSDThreshold;}
62
63   void    SetSDigitsBranch(const char* file) ;
64
65   AliPHOSDigitizer & operator = (const AliPHOSDigitizer & rvalue)  {
66     // assignement operator requested by coding convention but not needed
67     abort() ;
68     return *this ; 
69   }
70
71 private:
72   Bool_t  Init() ; 
73   void    PrintDigits(Option_t * option) ;
74   void    WriteDigits(Int_t evt) ;            // Writes Digits for particular event
75
76 private:
77
78   Float_t fPedestal ;                // Calibration parameters 
79   Float_t fSlope ;                   // read from SDigitizer
80
81   AliRunDigitizer * fARD ;          //! Pointer to the Digitization Manager class
82   Float_t fPinNoise ;               // Electronics noise in EMC
83   Float_t fEMCDigitThreshold  ;     // Threshold for storing digits in EMC
84   Float_t fCPVNoise ;               // Noise in CPV
85   Float_t fCPVDigitThreshold  ;     // Threshold for storing digits in CPV
86   Float_t fPPSDNoise ;              // Noise in PPSD
87   Float_t fPPSDDigitThreshold ;     // Threshold for storing digits in PPSD
88   Int_t fDigitsInRun ;              //! Total number of digits in one run
89
90
91   ClassDef(AliPHOSDigitizer,1)  // description 
92
93 };
94
95
96 #endif // AliPHOSDigitizer_H