1 #ifndef ALIEMCALTRIGGERMAPPING_H
2 #define ALIEMCALTRIGGERMAPPING_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
9 Author: R. GUERNANE LPSC Grenoble CNRS/IN2P3
15 class AliEMCALGeometry;
17 class AliEMCALTriggerMapping : public TObject
20 AliEMCALTriggerMapping() : fNTRU(0), fGeometry(0x0) {}
21 AliEMCALTriggerMapping(const Int_t ntru, const AliEMCALGeometry* geo) : fNTRU(ntru), fGeometry(geo) {}
22 virtual ~AliEMCALTriggerMapping() {}
24 virtual Bool_t GetAbsFastORIndexFromTRU(const Int_t iTRU, const Int_t iADC, Int_t& id) const = 0;
25 virtual Bool_t GetAbsFastORIndexFromPositionInTRU(const Int_t iTRU, const Int_t iEta, const Int_t iPhi, Int_t& id) const = 0;
26 virtual Bool_t GetAbsFastORIndexFromPositionInSM(const Int_t iSM, const Int_t iEta, const Int_t iPhi, Int_t& id) const = 0;
27 virtual Bool_t GetAbsFastORIndexFromPositionInEMCAL(const Int_t iEta, const Int_t iPhi, Int_t& id) const = 0;
28 virtual Bool_t GetTRUFromAbsFastORIndex(const Int_t id, Int_t& iTRU, Int_t& iADC) const = 0;
29 virtual Bool_t GetPositionInTRUFromAbsFastORIndex(const Int_t id, Int_t& iTRU, Int_t& iEta, Int_t& iPhi) const = 0;
30 virtual Bool_t GetPositionInSMFromAbsFastORIndex(const Int_t id, Int_t& iSM, Int_t& iEta, Int_t& iPhi) const = 0;
31 virtual Bool_t GetPositionInEMCALFromAbsFastORIndex(const Int_t id, Int_t& iEta, Int_t& iPhi) const = 0;
32 virtual Bool_t GetFastORIndexFromCellIndex(const Int_t id, Int_t& idx) const = 0;
33 virtual Bool_t GetCellIndexFromFastORIndex(const Int_t id, Int_t idx[4]) const = 0;
34 virtual Bool_t GetTRUIndexFromSTUIndex(const Int_t id, Int_t& idx) const = 0;
35 virtual Bool_t GetTRUIndexFromOnlineIndex(const Int_t id, Int_t& idx) const = 0;
36 virtual Bool_t GetOnlineIndexFromTRUIndex(const Int_t id, Int_t& idx) const = 0;
37 virtual Bool_t GetFastORIndexFromL0Index(const Int_t iTRU, const Int_t id, Int_t idx[], const Int_t size) const = 0;
39 virtual Int_t GetTRUIndexFromSTUIndex( const Int_t id) const = 0;
40 virtual Int_t GetTRUIndexFromOnlineIndex(const Int_t id) const = 0;
41 virtual Int_t GetOnlineIndexFromTRUIndex(const Int_t id) const = 0;
43 virtual void GetNTRU(Int_t& n) {n = fNTRU;}
44 virtual Int_t GetNTRU() {return fNTRU;}
48 const AliEMCALGeometry* fGeometry;
51 AliEMCALTriggerMapping(const AliEMCALTriggerMapping& rhs);
52 AliEMCALTriggerMapping& operator=(const AliEMCALTriggerMapping& rhs);
54 ClassDef(AliEMCALTriggerMapping,1)