]> git.uio.no Git - u/mrichter/AliRoot.git/blob - MUON/mapping/AliMpConstants.h
Adding option for ownership of objects in the map
[u/mrichter/AliRoot.git] / MUON / mapping / AliMpConstants.h
1 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2  * See cxx source for full Copyright notice                               */
3
4 // $Id$
5 // $MpId: AliMpConstants.h,v 1.11 2006/05/24 13:58:07 ivana Exp $
6
7 /// \ingroup basic
8 /// \class AliMpConstants
9 /// \brief Globally used constants definition.
10 ///
11 /// \author David Guez, Ivana Hrivnacova; IPN Orsay
12
13 #ifndef ALI_MP_CONSTANTS_H
14 #define ALI_MP_CONSTANTS_H
15
16 #include <TObject.h>
17 #include "AliMpPlaneType.h"
18
19 class TVector2;
20
21 class AliMpConstants : public TObject
22 {
23  public:
24   AliMpConstants();
25   virtual ~AliMpConstants();
26
27   // static compare methods
28   static Bool_t  IsEqual(Double_t length1, Double_t length2);
29   static Bool_t  IsEqual(const TVector2& v1, const TVector2& v2);
30
31   // static get methods
32   static Double_t LengthTolerance();
33   static Double_t LengthStep();
34   static Int_t    StartPadIndex();
35   static Int_t    NofChambers();
36   static Int_t    NofGeomModules();
37   static Int_t    ManuMask(AliMpPlaneType planeType);
38   
39  private:
40   // unused derived functions
41   virtual Bool_t  IsEqual(const TObject*) const { return true; }
42  
43   // static data members
44   static const Double_t  fgkLengthTolerance;///< the length precision for tests
45   static const Double_t  fgkLengthStep;     ///< \brief the step in length used to move from
46                                             /// a geometric border inside (pad, motif)
47   static const Int_t     fgkStartPadIndex;  ///< global pad indices start value
48   static const Int_t     fgkNofChambers;    ///< number of chambers
49   static const Int_t     fgkNofGeomModules; ///< number of geometry modules
50   static const Int_t     fgkNonBendingManuMask; ///< bit to set to indicate a manu located in non-bending plane
51   
52   ClassDef(AliMpConstants,3) //Class for globally used constants definition
53 };
54
55 // inline functions
56
57 inline Double_t AliMpConstants::LengthTolerance() { return fgkLengthTolerance;}
58 inline Double_t AliMpConstants::LengthStep()      { return fgkLengthStep;}
59 inline Int_t    AliMpConstants::StartPadIndex()   { return fgkStartPadIndex;}
60 inline Int_t    AliMpConstants::NofChambers()     { return fgkNofChambers;}
61 inline Int_t    AliMpConstants::NofGeomModules()  { return fgkNofGeomModules;}
62
63 #endif //ALI_MP_CONSTANTS_H
64