1 #ifndef ALIFMDANAPARAMETERS_H
2 #define ALIFMDANAPARAMETERS_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights
6 * Latest changes by Hans Hjersing Dalsgaard, NBI, hans.dalsgaard@cern.ch
8 * See cxx source for full Copyright notice
11 //The design of this class is based on the AliFMDParameters class. Its purpose
12 //is to hold parameters for the analysis such as background correction and
15 //Author: Hans Hjersing Dalsgaard, NBI, hans.dalsgaard@cern.ch
17 //____________________________________________________________________
25 #ifndef ALIFMDUSHORTMAP_H
26 # include <AliFMDUShortMap.h>
28 #ifndef ALIFMDBOOLMAP_H
29 # include <AliFMDBoolMap.h>
31 #include "AliCDBEntry.h"
34 #include "TObjArray.h"
38 #include "AliFMDAnaCalibBackgroundCorrection.h"
39 #include "AliFMDAnaCalibEnergyDistribution.h"
40 //____________________________________________________________________
42 // Singleton class to handle various parameters (not geometry) of the
44 // Should get ata fromm Conditions DB.
47 class AliFMDAnaParameters : public TNamed
50 /** Enumeration of things to initialize */
53 kBackgroundCorrection = 0x1, // Background Correction
54 kEnergyDistributions = 0x2 // Energy Distributions
59 static AliFMDAnaParameters* Instance();
61 void Init(Bool_t forceReInit=kTRUE, UInt_t what=kBackgroundCorrection|kEnergyDistributions);
64 Float_t GetMPV(Int_t det, Char_t ring);
65 Float_t GetSigma(Int_t det, Char_t ring);
66 static const char* GetBackgroundPath() { return fgkBackgroundCorrection;}
67 static const char* GetEdistPath() { return fgkEnergyDists;}
68 TH2F* GetBackgroundCorrection(Int_t det, Char_t ring, Int_t vtxbin);
72 AliFMDAnaParameters();
74 AliFMDAnaParameters(const AliFMDAnaParameters& o)
77 fBackgroundArray(o.fBackgroundArray),
78 fEdistArray(o.fEdistArray)
80 AliFMDAnaParameters& operator=(const AliFMDAnaParameters&) { return *this; }
81 virtual ~AliFMDAnaParameters() {}
83 static AliFMDAnaParameters* fgInstance; // Static singleton instance
85 AliCDBEntry* GetEntry(const char* path, Bool_t fatal=kTRUE) const ;
86 void InitBackground();
87 void InitEnergyDists();
88 TH1F* GetEnergyDistribution(Int_t det, Char_t ring);
89 TObjArray* GetBackgroundArray();
95 TObjArray* fBackgroundArray;
96 TObjArray* fEdistArray;
97 AliFMDAnaCalibBackgroundCorrection* fBackground;
98 AliFMDAnaCalibEnergyDistribution* fEnergyDistribution;
99 static const char* fgkBackgroundCorrection;
100 static const char* fgkEnergyDists;
101 ClassDef(AliFMDAnaParameters,0) // Manager of parameters
105 //____________________________________________________________________