1 #ifndef ALICALORAWSTREAMV3_H
2 #define ALICALORAWSTREAMV3_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
8 ///////////////////////////////////////////////////////////////////////////////
10 /// This class provides access to Calo digits in raw data.
12 /// Yuri Kharlov. 23 June 2009
14 ///////////////////////////////////////////////////////////////////////////////
16 // --- ROOT system ---
19 // --- AliRoot header files ---
20 #include "AliAltroRawStreamV3.h"
22 class AliAltroMapping;
24 class AliCaloRawStreamV3: public AliAltroRawStreamV3 {
27 AliCaloRawStreamV3(AliRawReader* rawReader, TString calo, AliAltroMapping **mapping = NULL);
28 virtual ~AliCaloRawStreamV3();
31 virtual Bool_t NextChannel();
33 Int_t GetModule() const {return fModule;}
34 Int_t GetRow() const {return fRow ;} // EMCAL notation
35 Int_t GetColumn() const {return fColumn;} // EMCAL notation
36 Int_t GetCellX() const {return fRow ;} // PHOS notation
37 Int_t GetCellZ() const {return fColumn;} // PHOS notation
38 Int_t GetNRCU() const {return fNRCU ;}
39 Int_t GetNSides() const {return fNSides;}
40 TString GetCalorimeter() const {return fCalo ;}
42 enum EAliCaloFlag { kLowGain=0, kHighGain=1, kTRUData=2, kLEDMonData=3 };
43 Bool_t IsLowGain() const {return (fCaloFlag == kLowGain) ;}
44 Bool_t IsHighGain() const {return (fCaloFlag == kHighGain) ;}
45 Bool_t IsTRUData() const {return (fCaloFlag == kTRUData) ;}
46 Bool_t IsLEDMonData() const {return (fCaloFlag == kLEDMonData);}
48 Int_t GetCaloFlag() const { return fCaloFlag; }
52 AliCaloRawStreamV3& operator = (const AliCaloRawStreamV3& stream);
53 AliCaloRawStreamV3(const AliCaloRawStreamV3& stream);
55 virtual void ApplyAltroMapping();
57 Int_t fModule; // index of current module
58 Int_t fRow; // index of current row
59 Int_t fColumn; // index of current column
60 Int_t fCaloFlag; // low (0) or (1) high gain; see enum EAliCaloFlag above
61 Int_t fNModules; // number of (super)modules
62 Int_t fNRCU; // number of RCU per (super)module
63 Int_t fNSides; // Division of EMCal in "A" "C" sides
64 TString fCalo; // Calorimeter name
65 Bool_t fExternalMapping; // use external mapping or create a default one
66 AliAltroMapping *fMapping[20]; // pointers to ALTRO mapping
68 ClassDef(AliCaloRawStreamV3, 3) // class for reading PHOS/EMCAL raw digits