1 #ifndef AliTRDCOMMONPARAM_H
2 #define AliTRDCOMMONPARAM_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
6 ///////////////////////////////////////////////////////////////////////////////
8 // Class containing constant common parameters //
10 ///////////////////////////////////////////////////////////////////////////////
18 class AliTRDCommonParam : public TObject
23 enum { kNplan = 6, kNcham = 5, kNsect = 18, kNdet = 540 };
25 AliTRDCommonParam(const AliTRDCommonParam &p);
26 AliTRDCommonParam &operator=(const AliTRDCommonParam &p);
27 virtual ~AliTRDCommonParam();
29 static AliTRDCommonParam *Instance();
30 static void Terminate();
32 virtual void Copy(TObject &p) const;
34 void SetField(Float_t field) { fField = field; };
35 void SetExB(Int_t exbOn = 1) { fExBOn = exbOn; };
37 Float_t GetField() const { return fField; };
38 Bool_t ExBOn() const { return fExBOn; };
40 AliTRDpadPlane *GetPadPlane(Int_t p, Int_t c) const;
41 Int_t GetRowMax(Int_t p, Int_t c, Int_t /*s*/) const;
42 Int_t GetColMax(Int_t p) const;
43 Double_t GetRow0(Int_t p, Int_t c, Int_t /*s*/) const;
44 Double_t GetCol0(Int_t p) const;
48 static AliTRDCommonParam *fgInstance; // Instance of this class (singleton implementation)
49 static Bool_t fgTerminated; // Defines if this class has already been terminated
53 Float_t fField; // Magnetic field
54 Int_t fExBOn; // Switch for the ExB effects
56 TObjArray *fPadPlaneArray; //! Array of pad plane objects
60 // This is a singleton, constructor is private!
63 ClassDef(AliTRDCommonParam,1) // The constant parameters common to simulation and reconstruction