1 #ifndef ALIFMDFLOATMAP_H
2 #define ALIFMDFLOATMAP_H
3 /* Copyright(c) 1998-2000, ALICE Experiment at CERN, All rights
6 * See cxx source for full Copyright notice
9 # include "AliFMDMap.h"
11 //____________________________________________________________________
13 // Array of floats indexed by strip identifier.
14 // the floats are indexed by the coordinates
16 // RING ID ('I' or 'O', any case)
20 class AliFMDFloatMap : public AliFMDMap
24 AliFMDFloatMap(Int_t maxDet,
28 AliFMDFloatMap(const AliFMDMap& o);
29 AliFMDFloatMap(const AliFMDFloatMap& o);
30 virtual ~AliFMDFloatMap() { delete [] fData;fData = 0; }
31 AliFMDFloatMap& operator=(const AliFMDFloatMap& o);
32 virtual void Reset(const Float_t& v=Float_t());
33 virtual Float_t& operator()(UShort_t det,
37 virtual const Float_t& operator()(UShort_t det,
41 Float_t* Data() const { return fData; }
42 void Print(Option_t* option="%8.4f") const { AliFMDMap::Print(option); }
43 void* Ptr() const { return reinterpret_cast<void*>(fData); }
45 Int_t MaxIndex() const { return fTotal; }
46 Float_t AtAsFloat(Int_t i) const { return fData[i]; }
47 Float_t& AtAsFloat(Int_t i) { return fData[i]; }
48 Bool_t IsFloat() const { return kTRUE; }
50 Int_t fTotal; // Total number of entries
51 Float_t* fData; //[fTotal]
52 ClassDef(AliFMDFloatMap,3) // Map of floats
56 operator*(const AliFMDMap& lhs, const AliFMDMap& rhs)
58 AliFMDFloatMap r(lhs);
63 operator/(const AliFMDMap& lhs, const AliFMDMap& rhs)
65 AliFMDFloatMap r(lhs);
70 operator+(const AliFMDMap& lhs, const AliFMDMap& rhs)
72 AliFMDFloatMap r(lhs);
77 operator-(const AliFMDMap& lhs, const AliFMDMap& rhs)
79 AliFMDFloatMap r(lhs);
85 //____________________________________________________________________