Calibration objects for EMC and CPV
[u/mrichter/AliRoot.git] / PHOS / AliPHOSCalibData.h
CommitLineData
52783dbc 1#ifndef ALIPHOSCALIBDATA_H
2#define ALIPHOSCALIBDATA_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7/* $Id$ */
8
9////////////////////////////////////////////////
fc6706cb 10// class for PHOS calibration //
52783dbc 11////////////////////////////////////////////////
12
13#include "TNamed.h"
fc6706cb 14#include "TString.h"
15#include "AliPHOSEmcCalibData.h"
16#include "AliPHOSCpvCalibData.h"
17#include "AliCDBMetaData.h"
52783dbc 18
19class AliPHOSCalibData: public TNamed {
20
21 public:
22 AliPHOSCalibData();
fc6706cb 23 AliPHOSCalibData(Int_t runNumber);
52783dbc 24 virtual ~AliPHOSCalibData();
25 void Reset();
26 virtual void Print(Option_t *option = "") const;
fc6706cb 27
28 void CreateNew();
29 void RandomEmc();
30 void RandomCpv();
31
072de3a8 32 Float_t GetADCchannelEmc(Int_t module, Int_t column, Int_t row) const;
33 Float_t GetADCpedestalEmc(Int_t module, Int_t column, Int_t row) const;
fc6706cb 34
072de3a8 35 void SetADCchannelEmc(Int_t module, Int_t column, Int_t row, Float_t value);
36 void SetADCpedestalEmc(Int_t module, Int_t column, Int_t row, Float_t value);
52783dbc 37
fc6706cb 38 Float_t GetADCchannelCpv(Int_t module, Int_t column, Int_t row) const;
39 Float_t GetADCpedestalCpv(Int_t module, Int_t column, Int_t row) const;
40
41 void SetADCchannelCpv(Int_t module, Int_t column, Int_t row, Float_t value);
42 void SetADCpedestalCpv(Int_t module, Int_t column, Int_t row, Float_t value);
43
44 void SetDB(const char* db) {fDB=db;}
45 void SetEmcDataPath(const char* emcPath) {fEmcDataPath=emcPath;}
46 void SetCpvDataPath(const char* cpvPath) {fCpvDataPath=cpvPath;}
47
48 Bool_t WriteEmc(Int_t firstRun, Int_t lastRun, AliCDBMetaData *md);
49 Bool_t WriteCpv(Int_t firstRun, Int_t lastRun, AliCDBMetaData *md);
50
51 private:
52
53 AliPHOSEmcCalibData* fCalibDataEmc; // EMC calibration data
54 AliPHOSCpvCalibData* fCalibDataCpv; // CPV calibration data
55
56 TString fDB;
57 TString fEmcDataPath; // path to EMC calibration data
58 TString fCpvDataPath; // path to CPV calibration data
59
52783dbc 60 //
61 ClassDef(AliPHOSCalibData,1) // PHOS Calibration data
62};
63
64#endif