]> git.uio.no Git - u/mrichter/AliRoot.git/blame - EMCAL/SMcalib/AliEMCALMapAPD.h
silvermy@ornl.gov - SMcalib - directory with tools for SuperModule calibrations at...
[u/mrichter/AliRoot.git] / EMCAL / SMcalib / AliEMCALMapAPD.h
CommitLineData
a8827307 1#ifndef ALIEMCALMAPAPD_H
2#define ALIEMCALMAPAPD_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#include <TObject.h>
10class TString;
11
12static const int fgkEmCalRows = 24; // number of rows per module for EMCAL
13static const int fgkEmCalCols = 48; // number of columns per module for EMCAL
14
15/*
16 Objects of this class read txt file with APD data
17 AliEMCALMapAPD inherits TObject only to use AliLog "functions".
18*/
19
20class AliEMCALMapAPD : public TObject {
21public:
22 AliEMCALMapAPD();
23
24 void ReadMapAPDInfoStripBasis(Int_t nSM, const TString &txtFileName); // info file is for nSm=1 to 12 SuperModules
25 void ReadMapAPDInfoSingleStripBasis(Int_t iSM, Int_t iStrip, const TString &txtFileName); // info file is for one single SuperModule and StripModule
26
27 void ReadMapAPDInfo(Int_t nSM, const TString &txtFileName); // info file is for nSm=1 to 12 SuperModules
28
29 void WriteMapAPDInfo(const TString &txtFileName); // info file is for nSm=1 to 12 SuperModules
30
31 void GenerateDummyAPDInfo(Int_t nSM, Int_t * iSM); // for debug purposes
32
33 virtual ~AliEMCALMapAPD();
34
35 struct AliEMCALSuperModuleMapAPD {
36 Int_t fSuperModuleNum;
37 Int_t fAPDNum[fgkEmCalCols][fgkEmCalRows];
38 };
39
40 // pointer to stored info.
41 Int_t GetNSuperModule() const { return fNSuperModule; };
42 AliEMCALSuperModuleMapAPD * GetSuperModuleData() const { return fSuperModuleData; };
43
44 // - via the index in the stored array:
45 virtual AliEMCALSuperModuleMapAPD GetSuperModuleMapAPDId(Int_t smIndex) const;
46 // - or via the actual SM number
47 virtual AliEMCALSuperModuleMapAPD GetSuperModuleMapAPDNum(Int_t smNum) const;
48
49protected:
50
51 Int_t fNSuperModule; // Number of supermodules.
52 AliEMCALSuperModuleMapAPD *fSuperModuleData; // SuperModule data
53
54private:
55
56 AliEMCALMapAPD(const AliEMCALMapAPD &);
57 AliEMCALMapAPD &operator = (const AliEMCALMapAPD &);
58
59 ClassDef(AliEMCALMapAPD, 1) //MapAPD data reader
60};
61
62#endif