]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - STEER/AliQADataMaker.h
Make and print an image of QA user flagged histograms (Yves)
[u/mrichter/AliRoot.git] / STEER / AliQADataMaker.h
index 9e7ea6cf1687771acec7cfd5409678e68749fca7..e07b211dbe8fea42c33a4dba1329b0638759f6b6 100644 (file)
@@ -30,7 +30,8 @@ class AliDetectorRecoParam;
 // --- Standard library ---
 
 // --- AliRoot header files ---
-#include "AliQA.h"
+#include "AliQAv1.h"
+#include "AliRecoParam.h" 
 
 class AliQADataMaker: public TNamed {
   
@@ -40,15 +41,15 @@ public:
        AliQADataMaker(const AliQADataMaker& qadm) ;   
        virtual ~AliQADataMaker() {} // dtor
   
-       virtual Int_t Add2DigitsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE)          = 0 ; 
-       virtual Int_t Add2ESDsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE)            = 0 ; 
-       virtual Int_t Add2HitsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE)            = 0 ; 
-       virtual Int_t Add2RecPointsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE)       = 0 ; 
-       virtual Int_t Add2RawsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE, const Bool_t saveForCorr = kFALSE)            = 0 ; 
-       virtual Int_t Add2SDigitsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE)         = 0 ; 
-       virtual void        Exec(AliQA::TASKINDEX_t, TObject * data)         = 0 ;
-       virtual void        EndOfCycle()                                     = 0 ;
-       virtual void        EndOfCycle(AliQA::TASKINDEX_t)                   = 0 ;
+       virtual Int_t Add2DigitsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE, const Bool_t image = kFALSE)          = 0 ; 
+       virtual Int_t Add2ESDsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE, const Bool_t image = kFALSE)            = 0 ; 
+       virtual Int_t Add2HitsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE, const Bool_t image = kFALSE)            = 0 ; 
+       virtual Int_t Add2RecPointsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE, const Bool_t image = kFALSE)       = 0 ; 
+       virtual Int_t Add2RawsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE, const Bool_t saveForCorr = kFALSE, const Bool_t image = kFALSE)            = 0 ; 
+       virtual Int_t Add2SDigitsList(TH1 * hist, const Int_t index, const Bool_t expert = kFALSE, const Bool_t image = kFALSE)         = 0 ; 
+       virtual void        Exec(AliQAv1::TASKINDEX_t, TObject * data)                                       = 0 ;
+       virtual void        EndOfCycle()                                           = 0 ;
+       virtual void        EndOfCycle(AliQAv1::TASKINDEX_t        )                 = 0 ;
        void                Finish() const ; 
        virtual TH1 *       GetDigitsData(const Int_t index)                       = 0 ; 
        virtual TH1 *       GetESDsData(const Int_t index)                         = 0 ; 
@@ -57,27 +58,30 @@ public:
        virtual TH1 *       GetRawsData(const Int_t index)                         = 0 ; 
        virtual TH1 *       GetSDigitsData(const Int_t index)                      = 0 ; 
        const char *        GetDetectorDirName() const { return fDetectorDirName.Data() ; }
-  TList *             GetParameterList() const { return fParameterList ; }
-       const Int_t         Increment() { return ++fCycleCounter ; } 
-       virtual TObjArray * Init(AliQA::TASKINDEX_t, Int_t cycles = -1)                              = 0 ;
-       virtual void        Init(AliQA::TASKINDEX_t, TObjArray * list, Int_t run, Int_t cycles = -1) = 0 ;
-       const Bool_t        IsCycleDone() const { return fCycleCounter > fCycle ? kTRUE : kFALSE ; }
+  TList *             GetParameterList() const { return fParameterList[AliRecoParam::AConvert(fEventSpecie)] ; }
+       Int_t               Increment() { return ++fCycleCounter ; } 
+       virtual TObjArray** Init(AliQAv1::TASKINDEX_t, Int_t cycles = -1)                               = 0 ;
+       virtual void        Init(AliQAv1::TASKINDEX_t, TObjArray ** list, Int_t run, Int_t cycles = -1) = 0 ;
+       Bool_t              IsCycleDone() const { return fCycleCounter > fCycle ? kTRUE : kFALSE ; }
+  virtual void        MakeImage(AliQAv1::TASKINDEX_t task) = 0 ; 
        void                Reset() { fCycleCounter = 0 ; }
        void                SetCycle(Int_t nevts) { fCycle = nevts ; } 
   void                SetWriteExpert() { fWriteExpert = kTRUE ; }
-       virtual void        StartOfCycle(Int_t run = -1)                                                      = 0 ;
-       virtual void        StartOfCycle(AliQA::TASKINDEX_t, Int_t run, const Bool_t sameCycle = kFALSE) = 0 ;
+       virtual void        StartOfCycle(Int_t run = -1)                                                 = 0 ;
+       virtual void        StartOfCycle(AliQAv1::TASKINDEX_t, Int_t run, const Bool_t sameCycle = kFALSE) = 0 ;
   void                UnSetWriteExpert() { fWriteExpert = kFALSE ; }
   Bool_t              WriteExpert() { return fWriteExpert ; }
-
-       virtual void        SetRecoParam(const AliDetectorRecoParam */*param*/) { return; }
+  void                SetEventSpecie(AliRecoParam::EventSpecie_t es) { fEventSpecie = es ; }
+  void                SetEventSpecie(Int_t es) { fEventSpecie = AliRecoParam::Convert(es) ; }
+       virtual void        SetRecoParam(const AliDetectorRecoParam */*param*/) {AliInfo("To be implemented by AliQADataMakerRec, not needed yet in Sim") ; } 
          
 protected: 
 
-       Int_t          Add2List(TH1 * hist, const Int_t index, TObjArray * list, const Bool_t expert = kFALSE, const Bool_t saveForCorr = kFALSE) ;
-       virtual void   DefaultEndOfDetectorCycle(AliQA::TASKINDEX_t task ) ; 
-       virtual void   EndOfDetectorCycle(AliQA::TASKINDEX_t task, TObjArray * obj ) = 0 ; 
-       TObject *      GetData(TObjArray * list, const Int_t index) ;
+       Int_t          Add2List(TH1 * hist, const Int_t index, TObjArray ** list, const Bool_t expert = kFALSE, const Bool_t image = kFALSE, const Bool_t saveForCorr = kFALSE) ;
+  TH1 *          CloneMe(TH1 * hist, Int_t specie) const ; 
+       virtual void   DefaultEndOfDetectorCycle(AliQAv1::TASKINDEX_t task ) ; 
+       virtual void   EndOfDetectorCycle(AliQAv1::TASKINDEX_t task, TObjArray ** list ) = 0 ; 
+       TObject *      GetData(TObjArray ** list, const Int_t index) ;
        virtual void   InitDigits()        = 0 ; 
        virtual void   InitESDs()          = 0 ; 
        virtual void   InitHits()          = 0 ; 
@@ -107,9 +111,9 @@ protected:
        Int_t          fCycle ;           //! length (# events) of the QA data acquisition cycle  
        Int_t          fCycleCounter ;    //! cycle counter
   Bool_t         fWriteExpert ;     //! flag to write or not the expert QA data
-  TList *        fParameterList ;   //! list of QA data parameters
+  TList **       fParameterList ;   //! list of QA data parameters
        Int_t          fRun ;             //! run number
-
+  AliRecoParam::EventSpecie_t fEventSpecie ; //! event specie, see AliRecoParam
 private:
        AliQADataMaker& operator = (const AliQADataMaker& /*qadm*/); // Not implemented