LCOV - code coverage report
Current view: top level - PHOS/PHOSbase - AliPHOSDigitizer.h (source / functions) Hit Total Coverage
Test: coverage.info Lines: 2 3 66.7 %
Date: 2016-06-14 17:26:59 Functions: 3 7 42.9 %

          Line data    Source code
       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             : /* History of cvs commits:
       9             :  *
      10             :  * $Log$
      11             :  * Revision 1.37  2007/10/10 09:05:10  schutz
      12             :  * Changing name QualAss to QA
      13             :  *
      14             :  * Revision 1.36  2007/09/30 17:08:20  schutz
      15             :  * Introducing the notion of QA data acquisition cycle (needed by online)
      16             :  *
      17             :  * Revision 1.35  2007/08/07 14:12:03  kharlov
      18             :  * Quality assurance added (Yves Schutz)
      19             :  *
      20             :  * Revision 1.34  2006/04/29 20:25:30  hristov
      21             :  * Decalibration is implemented (Yu.Kharlov)
      22             :  *
      23             :  * Revision 1.33  2005/05/28 14:19:04  schutz
      24             :  * Compilation warnings fixed by T.P.
      25             :  *
      26             :  */
      27             : 
      28             : //_________________________________________________________________________
      29             : //  Task Class for making SDigits in PHOS      
      30             : // Class performs digitization of Summable digits (in the PHOS case this is just
      31             : // sum of contributions of all primary particles into given cell). 
      32             : // In addition it performs mixing of summable digits from different events.
      33             : //                  
      34             : //*-- Author: Dmitri Peressounko(SUBATECH & KI)
      35             : 
      36             : 
      37             : // --- ROOT system ---
      38             : //#include "TObjString.h"
      39             : class TArrayI ;
      40             : class TClonesArray ; 
      41             : 
      42             : // --- Standard library ---
      43             : 
      44             : // --- AliRoot header files ---
      45             : #include "AliDigitizer.h"
      46             : #include "AliConfig.h"
      47             : #include "AliPHOSPulseGenerator.h"
      48             : class AliDigitizationInput ;
      49             : class AliPHOSCalibData ; 
      50             : 
      51             : class AliPHOSDigitizer: public AliDigitizer {
      52             : 
      53             : public:
      54             :   AliPHOSDigitizer() ;          // ctor
      55             :   AliPHOSDigitizer(TString alirunFileNameFile, TString eventFolderName = AliConfig::GetDefaultEventFolderName()) ; 
      56             :   AliPHOSDigitizer(AliDigitizationInput * digInput) ;
      57             :   virtual ~AliPHOSDigitizer() ;       
      58             : 
      59             :   void    Digitize(Int_t event) ;            // Make Digits from SDigits 
      60             :   void    Digitize(Option_t *option);                  // Supervising method
      61             : 
      62           2 :   void   SetEventRange(Int_t first=0, Int_t last=-1) {fFirstEvent=first; fLastEvent=last; }
      63             : 
      64             :   //General
      65           0 :   Int_t   GetDigitsInRun()  const { return fDigitsInRun ;}  
      66             : 
      67             :   void    Print(const Option_t * = "")const ;
      68             :  
      69             : private:
      70             :   AliPHOSDigitizer(const AliPHOSDigitizer & dtizer) ;
      71             :   AliPHOSDigitizer & operator = (const AliPHOSDigitizer & /*rvalue*/);
      72             : 
      73             :   virtual Bool_t Init() ; 
      74             :   void    InitParameters() ; 
      75             :   void    PrintDigits(Option_t * option) ;
      76             :   void    Unload() ; 
      77             :   void    WriteDigits() ;                     // Writes Digits for the current event
      78             :   Float_t TimeOfNoise(void) const;            // Calculate time signal generated by noise
      79             : 
      80             :   Float_t TimeResolution(Float_t energy) ;    //TOF resolution
      81             : 
      82             :   //Calculate the time of crossing of the threshold by front edge
      83             :   //  Float_t FrontEdgeTime(TClonesArray * ticks) const ; 
      84             :   //Calculate digitized signal with gived ADC parameters
      85             :   Float_t Calibrate(Float_t amp, Int_t absId) ;
      86             :   Float_t CalibrateT(Float_t time, Int_t absId) ;
      87             :   void    Decalibrate(AliPHOSDigit * digit);
      88             :   Int_t   DigitizeCPV(Float_t charge, Int_t absId) ;
      89             : 
      90             : private:
      91             : 
      92             :   Bool_t  fDefaultInit;             //! Says if the task was created by defaut ctor (only parameters are initialized)
      93             :   Int_t   fDigitsInRun ;            //! Total number of digits in one run
      94             :   Bool_t  fInit ;                   //! To avoid overwriting existing files
      95             : 
      96             :   Int_t   fInput ;                  // Number of files to merge
      97             :   TString * fInputFileNames ;       //[fInput] List of file names to merge 
      98             :   TString * fEventNames ;           //[fInput] List of event names to merge
      99             : 
     100             :   Int_t   fEmcCrystals ;            // Number of EMC crystalls in the given geometry
     101             : 
     102             :   TString fEventFolderName;         // skowron: name of EFN to read data from in stand alone mode
     103             :   Int_t   fFirstEvent;              // first event to process
     104             :   Int_t   fLastEvent;               // last  event to process 
     105             :   AliPHOSCalibData* fcdb;           //! Calibration parameters DB
     106             : 
     107             :   Int_t fEventCounter ;             //! counts the events processed
     108             : 
     109             :   AliPHOSPulseGenerator *fPulse;    //! Pulse shape generator
     110             :   Int_t *fADCValuesLG;              //! Array of low-gain ALTRO samples
     111             :   Int_t *fADCValuesHG;              //! Array of high-gain ALTRO samples
     112             :   
     113          30 :   ClassDef(AliPHOSDigitizer,5)  // description 
     114             : 
     115             : };
     116             : 
     117             : 
     118             : #endif // AliPHOSDigitizer_H

Generated by: LCOV version 1.11