]> git.uio.no Git - u/mrichter/AliRoot.git/blob - MUON/AliMUONTest.h
Updated with refactoring of geometry & segmentation classes;
[u/mrichter/AliRoot.git] / MUON / AliMUONTest.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 //
6 /// \ingroup sim
7 /// \class AliMUONTest
8 /// \brief Class with functions for testing new segmentation
9 ///
10 /// Author: Ivana Hrivnacova, IPN Orsay
11
12 #ifndef ALI_MUON_TEST_H
13 #define ALI_MUON_TEST_H
14
15 #include <TObject.h>
16
17 class TCanvas;
18 class AliMUONGeometryTransformer;
19 class AliMUONSegmentation;
20 class AliMUONGeometrySegmentation;
21
22 enum AliMUONTests {
23   kPrintPads,
24   kDrawPads
25 };  
26
27 class AliMUONTest : public  TObject 
28 {
29   public:
30     AliMUONTest(const TString& option);
31     AliMUONTest();
32     virtual ~AliMUONTest();
33    
34     // Get segmentation
35     AliMUONGeometrySegmentation* GetSegmentation(
36                                        Int_t chamberId, Int_t cath);
37                                                           
38     // other tests
39     //
40     void DetElemTransforms();
41
42     // selected tests
43     //                                                    
44     void ForWhole(AliMUONTests test);
45     void ForSegmentation(
46                   AliMUONTests test,
47                   AliMUONGeometrySegmentation* segmentation);
48     void ForDetElement(
49                   AliMUONTests test,
50                   Int_t detElemId,
51                   AliMUONGeometrySegmentation* segmentation);
52     void Before(AliMUONTests test);
53     void After(AliMUONTests test);
54  
55     // tests per pad
56     //
57     void PrintPad(Int_t& counter, 
58                   Int_t detElemId, Int_t ix, Int_t iy,
59                   AliMUONGeometrySegmentation* segmentation);
60     void DrawPad(Int_t& counter, 
61                   Int_t detElemId, Int_t ix, Int_t iy,
62                   AliMUONGeometrySegmentation* segmentation);
63  
64
65     void DrawSegmentation(AliMUONGeometrySegmentation *seg);
66              // TBR                       
67                           
68
69   protected:
70     AliMUONTest(const AliMUONTest& rhs);
71     AliMUONTest& operator = (const AliMUONTest& rhs);
72     
73   private:  
74     // methods
75     void BuildWithMUON(const TString& configMacro);
76     void BuildWithoutMUON(const TString& option);
77
78     // data members
79     const AliMUONGeometryTransformer* fkTransformer; // Geometry parametrisation
80     AliMUONSegmentation*  fSegmentation;  // Segmentation
81     TCanvas*              fCanvas;        // The canvas for drawing                                    
82
83     ClassDef(AliMUONTest,0)  // MUON class for tests
84 };
85
86 #endif //ALI_MUON_TEST_H
87