]> git.uio.no Git - u/mrichter/AliRoot.git/blob - RAW/AliCaloAltroMapping.h
Fixes for coverity.
[u/mrichter/AliRoot.git] / RAW / AliCaloAltroMapping.h
1 #ifndef ALICALOALTROMAPPING_H
2 #define ALICALOALTROMAPPING_H
3 /* Copyright(c) 1998-2003, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice                               */
5
6 /* $Id$ */
7
8 //////////////////////////////////////////////////////////
9 // Class used to setup the mapping of hardware adresses //
10 // in ALTRO to Calo cells (column and row index +       //
11 // low/high gain.                                       //
12 // The mapping is defined in an external mapping files  //
13 // separately. The class derives from the base altro    //
14 // mapping class defined in the RAW package.            //
15 //////////////////////////////////////////////////////////
16
17 /// Exported from PHOS to be used also by EMCAL
18 /// November 2006 Gustavo Conesa Balbastre
19
20 #include "AliAltroMapping.h"
21
22 class AliCaloAltroMapping: public AliAltroMapping {
23  public:
24   AliCaloAltroMapping();
25   AliCaloAltroMapping(const char *mappingFile);
26   virtual ~AliCaloAltroMapping();
27
28   // In case of PHOS/EMCAL the relevant segmentation is row-column-gain
29   // or eta-phi-gain
30   virtual Int_t GetHWAddress(Int_t row, Int_t column, Int_t gain);
31   // Get Row (not pad-row as in the base class)
32   virtual Int_t GetPadRow(Int_t hwAddress) const;
33   // Get Column (not pad as in the base class)
34   virtual Int_t GetPad(Int_t hwAddress) const;
35   // Get Gain (0/1) (not sector as in the base class)
36   virtual Int_t GetSector(Int_t hwAddress) const;
37
38  protected:
39   virtual Bool_t ReadMapping();
40   virtual Bool_t CreateInvMapping();
41
42   Int_t     fMinRow;        // Minimum row index
43   Int_t     fMaxRow;        // Maximum row index
44   Int_t     fMinCol;        // Minimum column index
45   Int_t     fMaxCol;        // Maximum column index
46   Short_t  *fInvMappingLow; //! Inverse of fMapping (Low gain)
47   Short_t  *fInvMappingHigh;//! Inverse of fMapping (High gain)
48
49  private:
50
51   AliCaloAltroMapping(const AliCaloAltroMapping& mapping);
52   AliCaloAltroMapping& operator = (const AliCaloAltroMapping& mapping);
53
54   ClassDef(AliCaloAltroMapping,3)  // Altro mapping handler class
55 };
56
57 #endif