]>
Commit | Line | Data |
---|---|---|
fb921a27 | 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 geometry | |
7 | /// \class AliMUONSegmentation | |
8 | /// \brief Container class for modules segmentations | |
9 | /// | |
bd7d4869 | 10 | /// It provides access to segmentations on all levels: |
11 | /// - mapping segmentation | |
12 | /// - DE segmentation (operating in local DE reference frame) | |
13 | /// - module segmentation (operating in global reference frame) | |
14 | /// As some detection element are sharing the same objects | |
15 | /// (AliMpVSegmentation, AliMUONVGeometryDESegmentation), | |
16 | /// all segmentations objects have to be always deleted | |
17 | /// altogether via deleting this container object. | |
18 | /// | |
fb921a27 | 19 | /// Author: Ivana Hrivnacova, IPN Orsay |
20 | ||
21 | #ifndef ALI_MUON_SEGMENTATION_H | |
22 | #define ALI_MUON_SEGMENTATION_H | |
23 | ||
24 | #include <TObject.h> | |
25 | #include <TGeoMatrix.h> | |
26 | ||
27 | class TObjArray; | |
28 | ||
29 | class AliMpVSegmentation; | |
30 | ||
31 | class AliMUONGeometrySegmentation; | |
32 | class AliMUONVGeometryDESegmentation; | |
33 | ||
34 | class AliMUONSegmentation : public TObject | |
35 | { | |
36 | public: | |
37 | AliMUONSegmentation(Int_t nofModules); | |
38 | AliMUONSegmentation(); | |
39 | virtual ~AliMUONSegmentation(); | |
40 | ||
41 | // methods | |
bd7d4869 | 42 | void AddMpSegmentation(AliMpVSegmentation* segmentation); |
fb921a27 | 43 | void AddDESegmentation(AliMUONVGeometryDESegmentation* segmentation); |
44 | ||
45 | void AddModuleSegmentation(Int_t moduleId, Int_t cathod, | |
46 | AliMUONGeometrySegmentation* segmentation); | |
bd7d4869 | 47 | void Init(); |
48 | // This function should not be needed; | |
49 | // the segmentations should be built in a valid state | |
50 | // To be revised | |
fb921a27 | 51 | |
52 | // | |
53 | // get methods | |
54 | // | |
55 | ||
56 | // Geometry segmentations | |
57 | // | |
58 | AliMUONGeometrySegmentation* GetModuleSegmentation( | |
59 | Int_t moduleId, Int_t cathod, Bool_t warn = true) const; | |
60 | ||
61 | AliMUONGeometrySegmentation* GetModuleSegmentationByDEId( | |
62 | Int_t detElemId, Int_t cathod, Bool_t warn = true) const; | |
63 | ||
64 | // DE segmentations | |
65 | // | |
66 | const AliMUONVGeometryDESegmentation* GetDESegmentation( | |
67 | Int_t detElemId, Int_t cathod, Bool_t warn = true) const; | |
68 | ||
69 | // Mapping segmentations | |
70 | // | |
71 | const AliMpVSegmentation* GetMpSegmentation( | |
72 | Int_t detElemId, Int_t cathod, Bool_t warn = true) const; | |
73 | ||
74 | // DE properties | |
75 | // | |
76 | Bool_t HasDE(Int_t detElemId, Int_t cathod = 0) const; | |
77 | TString GetDEName(Int_t detElemId, Int_t cathod = 0) const; | |
78 | ||
79 | protected: | |
80 | AliMUONSegmentation(const AliMUONSegmentation& right); | |
81 | AliMUONSegmentation& operator = (const AliMUONSegmentation& right); | |
82 | ||
83 | private: | |
84 | // data members | |
bd7d4869 | 85 | TObjArray* fMpSegmentations; // array of mapping segmentations |
fb921a27 | 86 | TObjArray* fDESegmentations; // array of DE segmentations |
87 | TObjArray* fModuleSegmentations[2]; // array of module segmentations | |
88 | // for two cathods | |
89 | ||
48e3bf4c | 90 | ClassDef(AliMUONSegmentation,2) // Container class for module segmentations |
fb921a27 | 91 | }; |
92 | ||
93 | #endif //ALI_MUON_SEGMENTATION_H | |
94 | ||
95 | ||
96 | ||
97 | ||
98 | ||
99 | ||
100 |