]> git.uio.no Git - u/mrichter/AliRoot.git/blame - STEER/AliQualAssDataMaker.h
Oversight for debugging purpose fixed
[u/mrichter/AliRoot.git] / STEER / AliQualAssDataMaker.h
CommitLineData
421ab0fb 1#ifndef ALIQUALASSDATAMAKER_H
2#define ALIQUALASSDATAMAKER_H
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
9/*
10 Base Class:
11 Produces the data needed to calculate the quality assurance.
12 All data must be mergeable objects.
13 Y. Schutz CERN July 2007
14*/
15
16
17// --- ROOT system ---
6c18591a 18#include <TH1.h>
19#include <TList.h>
421ab0fb 20#include <TNamed.h>
21class TFile;
7079c8d7 22class TDirectory;
d76c31f4 23class TObject;
24class TTree;
25class AliESDEvent;
a5fa6165 26
421ab0fb 27// --- Standard library ---
28
29// --- AliRoot header files ---
30#include "AliQualAss.h"
31
32class AliQualAssDataMaker: public TNamed {
33
34public:
35
36 AliQualAssDataMaker(const char * name="", const char * title="") ; // ctor
37 AliQualAssDataMaker(const AliQualAssDataMaker& qadm) ;
38 AliQualAssDataMaker& operator = (const AliQualAssDataMaker& qadm) ;
39 virtual ~AliQualAssDataMaker() {;} // dtor
40
d76c31f4 41 virtual void Exec(AliQualAss::TASKINDEX, TObject * data) ;
5b188f2f 42 void EndOfCycle(AliQualAss::TASKINDEX) ;
421ab0fb 43 void Finish(AliQualAss::TASKINDEX task) const ;
44 static const char * GetDetectorDirName() { return fDetectorDirName.Data() ; }
5b188f2f 45 const Int_t Increment() { return ++fCycleCounter ; }
46 TList * Init(AliQualAss::TASKINDEX, Int_t run, Int_t cycles = -1) ;
47 const Bool_t IsCycleDone() const { return fCycleCounter > fCycle ? kTRUE : kFALSE ; }
48 const Int_t Add2DigitsList(TH1 * hist, Int_t index) { return Add2List(hist, index, fDigitsQAList) ; }
49 const Int_t Add2ESDsList(TH1 * hist, Int_t index) { return Add2List(hist, index, fESDsQAList) ; }
50 const Int_t Add2HitsList(TH1 * hist, Int_t index) { return Add2List(hist, index, fHitsQAList) ; }
51 const Int_t Add2RecPointsList(TH1 * hist, Int_t index) { return Add2List(hist, index, fRecPointsQAList) ; }
52 const Int_t Add2RawsList(TH1 * hist, Int_t index) { return Add2List(hist, index, fRawsQAList) ; }
53 const Int_t Add2SDigitsList(TH1 * hist, Int_t index) { return Add2List(hist, index, fSDigitsQAList) ; }
6c18591a 54 TH1 * GetDigitsData(Int_t index) { return dynamic_cast<TH1 *>(GetData(fDigitsQAList, index)) ; }
55 TH1 * GetESDsData(Int_t index) { return dynamic_cast<TH1 *>(GetData(fESDsQAList, index)) ; }
56 TH1 * GetHitsData(Int_t index) { return dynamic_cast<TH1 *>(GetData(fHitsQAList, index)) ; }
57 TH1 * GetRecPointsData(Int_t index) { return dynamic_cast<TH1 *>(GetData(fRecPointsQAList, index)) ; }
58 TH1 * GetRawsData(Int_t index) { return dynamic_cast<TH1 *>(GetData(fRawsQAList, index)) ; }
59 TH1 * GetSDigitsData(Int_t index) { return dynamic_cast<TH1 *>(GetData(fSDigitsQAList, index)) ; }
5b188f2f 60 void SetCycle(Int_t nevts) { fCycle = nevts ; }
61 void StartOfCycle(AliQualAss::TASKINDEX, Option_t * sameCycle = "") ;
6c18591a 62
421ab0fb 63protected:
64
6c18591a 65 Int_t Add2List(TH1 * hist, Int_t index, TList * list) { list->AddAt(hist, index) ; return list->LastIndex() ; }
5b188f2f 66 virtual void EndOfDetectorCycle() {AliInfo("To be implemented by detectors");}
6c18591a 67 TObject * GetData(TList * list, Int_t index) { return list->At(index) ; }
5b188f2f 68 virtual void InitDigits() {AliInfo("To be implemented by detectors");}
69 virtual void InitESDs() {AliInfo("To be implemented by detectors");}
70 virtual void InitHits() {AliInfo("To be implemented by detectors");}
71 //virtual void InitRecParticles() {AliInfo("To be implemented by detectors");}
72 virtual void InitRecPoints() {AliInfo("To be implemented by detectors");}
73 virtual void InitRaws() {AliInfo("To be implemented by detectors");}
74 virtual void InitSDigits() {AliInfo("To be implemented by detectors");}
6c18591a 75 //virtual void InitTrackSegments() {AliInfo("To ne implemented by detectors");}
5b188f2f 76 virtual void MakeESDs(AliESDEvent * ) {AliInfo("To be implemented by detectors");}
77 virtual void MakeHits(TObject * ) {AliInfo("To be implemented by detectors");}
78 virtual void MakeDigits(TObject * ) {AliInfo("To be implemented by detectors");}
79 // virtual void MakeRecParticles(TClonesArray * ) {AliInfo("To be implemented by detectors");}
80 virtual void MakeRaws(TObject * ) {AliInfo("To be implemented by detectors");}
81 virtual void MakeRecPoints(TTree * ) {AliInfo("To be implemented by detectors");}
82 virtual void MakeSDigits(TObject * ) {AliInfo("To be implemented by detectors");}
83 //virtual void MakeTrackSegments(TTree * ) {AliInfo("To be implemented by detectors");}
84 void ResetCycle() { fCycleCounter = 0 ; }
85 virtual void StartOfDetectorCycle() {AliInfo("To be implemented by detectors");}
421ab0fb 86
6c18591a 87 TFile * fOutput ; //! output root file
88 TDirectory * fDetectorDir ; //! directory for the given detector in the file
421ab0fb 89 static TString fDetectorDirName ; //! detector directory name in the quality assurance data file
6c18591a 90 TList * fDigitsQAList ; //! list of the digits QA data objects
91 TList * fESDsQAList ; //! list of the ESDs QA data objects
92 TList * fHitsQAList ; //! list of the hits QA data objects
93 TList * fRawsQAList ; //! list of the raws QA data objects
94 TList * fRecPointsQAList ; //! list of the recpoints QA data objects
95 TList * fSDigitsQAList ; //! list of the sdigits QA data objects
5b188f2f 96 Int_t fCurrentCycle ; //! current cycle number
97 Int_t fCycle ; //! length (# events) of the QA data acquisition cycle
98 Int_t fCycleCounter ; //! cycle counter
99 Int_t fRun ; //! run number
6c18591a 100 ClassDef(AliQualAssDataMaker,1) // description
421ab0fb 101
102};
103
104#endif // AliQualAssDataMaker_H