Bug fix. Removed delete statement
[u/mrichter/AliRoot.git] / STEER / AliQACheckerBase.h
CommitLineData
2e42b4d4 1#ifndef ALIQACHECKERBASE_H
2#define ALIQACHECKERBASE_H
421ab0fb 3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6
7/* $Id$ */
8
202374b1 9//
10// Base class for detectors quality assurance checkers
11// Compares Data made by QADataMakers with reference data
12// Y. Schutz CERN August 2007
13//
421ab0fb 14
15
16// --- ROOT system ---
17#include <TNamed.h>
4e25ac79 18#include "AliQAv1.h"
634696f5 19class TCanvas ;
421ab0fb 20class TFile ;
a5fa6165 21class TH1 ;
4edbc5bc 22class TObjArray ;
4b2b2b55 23class TDirectory ;
a2b64fbd 24class TNtupleD ;
421ab0fb 25
26// --- Standard library ---
27
28// --- AliRoot header files ---
29
2e42b4d4 30class AliQACheckerBase: public TNamed {
421ab0fb 31
32public:
2e42b4d4 33 AliQACheckerBase(const char * name = "", const char * title = "") ; // ctor
34 AliQACheckerBase(const AliQACheckerBase& qac) ;
35 AliQACheckerBase& operator = (const AliQACheckerBase& qac) ;
57acd2d2 36 virtual ~AliQACheckerBase() ; // dtor
2e42b4d4 37
634696f5 38 TCanvas ** GetImage() { return fImage ; }
39 TCanvas * GetImage(AliRecoParam::EventSpecie_t es) { return fImage[AliRecoParam::AConvert(es)] ; }
4e25ac79 40 virtual void Init(const AliQAv1::DETECTORINDEX_t det) { AliQAv1::Instance(det) ; }
634696f5 41 virtual void MakeImage( TObjArray ** list, AliQAv1::TASKINDEX_t task, AliQAv1::MODE_t mode) ;
4e25ac79 42 void Run(AliQAv1::ALITASK_t tsk, TObjArray ** list = NULL);
43 void Run(AliQAv1::ALITASK_t /*tsk*/, TNtupleD ** /*nt*/) {;}
57acd2d2 44 void SetHiLo(Float_t * hiValue, Float_t * lowValue) ;
634696f5 45 void SetPrintImage(Bool_t opt = kTRUE) { fPrintImage = opt ; }
57acd2d2 46 void SetRefandData(TDirectory * ref, TObjArray ** refOCDB, TDirectory * data=NULL) { fRefSubDir = ref ; fRefOCDBSubDir = refOCDB, fDataSubDir = data ; }
421ab0fb 47
48protected:
4e25ac79 49 virtual Double_t * Check(AliQAv1::ALITASK_t index) ;
50 virtual Double_t * Check(AliQAv1::ALITASK_t, TObjArray **) ;
57acd2d2 51
52 Double_t DiffC(const TH1 * href, const TH1 * hin) const ;
53 Double_t DiffK(const TH1 * href, const TH1 * hin) const ;
54 void Finish() const ;
4e25ac79 55 virtual void SetQA(AliQAv1::ALITASK_t index, Double_t * value) const ;
57acd2d2 56
57 TDirectory * fDataSubDir ; //! directory for the current task directory in the current detector directory in the data file
58 TDirectory * fRefSubDir ; //! directory for the current task directory in the current detector directory in the reference file
59 TObjArray ** fRefOCDBSubDir ; //! Entry in OCDB for the current detector
60 Float_t * fLowTestValue ; // array of lower bounds for INFO, WARNING, ERROR, FATAL
61 Float_t * fUpTestValue ; // array of upper bounds for INFO, WARNING, ERROR, FATAL
634696f5 62 TCanvas ** fImage ;//[AliRecoParam::kNSpecies]
63 Bool_t fPrintImage ;//! flag to print the images or not
421ab0fb 64
634696f5 65 ClassDef(AliQACheckerBase,2) // description
421ab0fb 66
67};
68
69#endif // AliQUALASSCHECKERBASE_H