]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGGA/PHOSTasks/CaloCellQA/AliAnalysisTaskCaloCellsQA.h
fbe381afbb1774dc3e49dc006a72df1873465fdc
[u/mrichter/AliRoot.git] / PWGGA / PHOSTasks / CaloCellQA / AliAnalysisTaskCaloCellsQA.h
1 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2  * See cxx source for full Copyright notice                               */
3
4 //_________________________________________________________________________
5 // Container class for bad channels & bad runs identification
6 // Author: Olga Driga (SUBATECH)
7
8 #ifndef ALIANALYSISTASKCALOCELLSQA_H
9 #define ALIANALYSISTASKCALOCELLSQA_H
10
11 // --- ROOT system ---
12 #include <TString.h>
13
14 // --- AliRoot header files ---
15 #include <AliAnalysisTaskSE.h>
16 #include <AliCaloCellsQA.h>
17
18 class AliAnalysisTaskCaloCellsQA : public AliAnalysisTaskSE {
19
20 public:
21
22   // detectors
23   enum {
24     kEMCAL = 0,
25     kPHOS  = 1
26 // ,kDCAL  = 2      // not implemented
27   };
28
29   AliAnalysisTaskCaloCellsQA();
30   AliAnalysisTaskCaloCellsQA(const char *name, Int_t nmods = 10, Int_t det = kEMCAL, char *outfile = NULL);
31   virtual ~AliAnalysisTaskCaloCellsQA();
32
33   void   UserCreateOutputObjects();
34   void   UserExec(Option_t *);
35   void   Terminate(Option_t *);
36
37   void   SetBadCells(Int_t badcells[], Int_t nbad);
38
39   // getters and setters
40   AliCaloCellsQA*  GetCaloCellsQA()                { return fCellsQA; }
41   Bool_t           GetAvoidPileup()                { return fkAvoidPileup; }
42   const char*      GetOutputFileName()             { return fOutfile.Data(); }
43   void             SetAvoidPileup(Bool_t flag)     { fkAvoidPileup = flag; }
44   void             SetOutputFileName(char* fname)  { fOutfile = fname; }
45
46 protected:
47   Bool_t IsClusterBad(AliVCluster *clus);
48
49 private:
50   AliAnalysisTaskCaloCellsQA(const AliAnalysisTaskCaloCellsQA &);
51   AliAnalysisTaskCaloCellsQA & operator = (const AliAnalysisTaskCaloCellsQA &);
52
53 private:
54   Bool_t           fkAvoidPileup;     // flag not to process pileup events
55   AliCaloCellsQA*  fCellsQA;          // analysis instance
56   TString          fOutfile;          // output file name
57   Int_t            fNBad;             // number of entries in fBadCells
58   Int_t*           fBadCells;         //[fNBad] bad cells array
59
60   ClassDef(AliAnalysisTaskCaloCellsQA, 2);
61 };
62
63 #endif