From Kalliopi: Updated HLT histogram filling
[u/mrichter/AliRoot.git] / HLT / EVE / AliHLTEveBase.h
CommitLineData
33791895 1/* This file is property of and copyright by the ALICE HLT Project *
2 * ALICE Experiment at CERN, All rights reserved. *
3 * See cxx source for full Copyright notice */
4
5/// @file AliHLTEveBase.h
6/// @author Svein Lindal
7/// @brief Base class for the HLT eve display elements
8
9#ifndef ALIHLTEVEBASE_H
10#define ALIHLTEVEBASE_H
11
12#include "Rtypes.h"
3d600a8b 13#include "TString.h"
14
33791895 15class AliHLTHOMERBlockDesc;
16class AliEveHOMERManager;
17class TCanvas;
3d600a8b 18
33791895 19
20class AliHLTEveBase{
21
22public:
23
24 /** Default constructor prohibited **/
25 AliHLTEveBase();
26
27 /** Destructor **/
28 virtual ~AliHLTEveBase();
29
30 /** Process the incoming blocks, must be implemented by children */
31 virtual void ProcessBlock(AliHLTHOMERBlockDesc * block) = 0;
32
33 /** Update the elements after new event loaded, to be implemented by children */
34 virtual void UpdateElements() = 0;
35
36 /** Reset the elements before reading in new event, to be implemented by children */
37 virtual void ResetElements() = 0;
38
39 /** Set the parent AliEveHOMERManager instance */
40 void SetEventManager(AliEveHOMERManager * em) { fEventManager = em; };
41
42
43
44protected:
45
46 /** Create a new canvas tab */
47 TCanvas * CreateCanvas(TString tabTitle, TString canvasTitle );
48
49 /** Addhistograms to the canvas */
50 virtual void AddHistogramsToCanvas(AliHLTHOMERBlockDesc * block, TCanvas * canvas, Int_t &cdCount );
51
3d600a8b 52
53 /// Getters and setters for the max number of histograms
54 void SetMaxHistograms(Int_t mh) {fMaxHistos = mh;}
55 Int_t GetMaxHistograms() const {return fMaxHistos;}
56
57 ///Getter and setter for the detector string
58 void SetDetector(TString det) {fDetector = det;}
59 TString GetDetector() const {return fDetector;}
60
33791895 61
62 AliEveHOMERManager * fEventManager; //Pointer to AliEveHOMERManager instance
63 TCanvas * fCanvas; //Canvas for histograms
64 Int_t fHistoCount; //Counter for histograms, to track where to draw the next one
65
66
67private:
68
69 /** copy constructor prohibited */
70 AliHLTEveBase(const AliHLTEveBase&);
71 /** assignment operator prohibited */
72 AliHLTEveBase& operator=(const AliHLTEveBase&);
73
3d600a8b 74 Int_t fMaxHistos; // Maximum number histograms there is room for.
75
76 TString fDetector; //String denoting the detector
77
33791895 78 ClassDef(AliHLTEveBase, 0);
79};
80
81#endif