1 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2 * See cxx source for full Copyright notice */
7 /// \class AliMUONSegmentation
8 /// \brief Container class for modules segmentations
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.
19 /// Author: Ivana Hrivnacova, IPN Orsay
21 #ifndef ALI_MUON_SEGMENTATION_H
22 #define ALI_MUON_SEGMENTATION_H
25 #include <TGeoMatrix.h>
29 class AliMpVSegmentation;
31 class AliMUONGeometrySegmentation;
32 class AliMUONVGeometryDESegmentation;
34 class AliMUONSegmentation : public TObject
37 AliMUONSegmentation(Int_t nofModules);
38 AliMUONSegmentation();
39 virtual ~AliMUONSegmentation();
42 void AddMpSegmentation(AliMpVSegmentation* segmentation);
43 void AddDESegmentation(AliMUONVGeometryDESegmentation* segmentation);
45 void AddModuleSegmentation(Int_t moduleId, Int_t cathod,
46 AliMUONGeometrySegmentation* segmentation);
48 // This function should not be needed;
49 // the segmentations should be built in a valid state
56 // Geometry segmentations
58 AliMUONGeometrySegmentation* GetModuleSegmentation(
59 Int_t moduleId, Int_t cathod, Bool_t warn = true) const;
61 AliMUONGeometrySegmentation* GetModuleSegmentationByDEId(
62 Int_t detElemId, Int_t cathod, Bool_t warn = true) const;
66 const AliMUONVGeometryDESegmentation* GetDESegmentation(
67 Int_t detElemId, Int_t cathod, Bool_t warn = true) const;
69 /** Mapping segmentations access by cathode number.
70 cathod can be 0 or 1. Note that there's no trivial relationship
71 between the cathode number and whether the corresponding plane
72 is a Bending or NonBending one.
74 const AliMpVSegmentation* GetMpSegmentation(
75 Int_t detElemId, Int_t cathod, Bool_t warn = true) const;
79 Bool_t HasDE(Int_t detElemId, Int_t cathod = 0) const;
80 TString GetDEName(Int_t detElemId, Int_t cathod = 0) const;
83 AliMUONSegmentation(const AliMUONSegmentation& right);
84 AliMUONSegmentation& operator = (const AliMUONSegmentation& right);
88 TObjArray* fMpSegmentations; // array of mapping segmentations
89 TObjArray* fDESegmentations; // array of DE segmentations
90 TObjArray* fModuleSegmentations[2]; // array of module segmentations
92 ClassDef(AliMUONSegmentation,2) // Container class for module segmentations
95 #endif //ALI_MUON_SEGMENTATION_H