]>
Commit | Line | Data |
---|---|---|
5f91c9e8 | 1 | // $Id$ |
2 | // Category: sector | |
3 | // | |
4 | // Class AliMpSector | |
5 | // ----------------- | |
6 | // Class describing the sector of the MUON chamber of station 1. | |
7 | // | |
8 | // Authors: David Guez, Ivana Hrivnacova; IPN Orsay | |
9 | ||
10 | #ifndef ALI_MP_SECTOR_H | |
11 | #define ALI_MP_SECTOR_H | |
12 | ||
5f91c9e8 | 13 | #include <TObject.h> |
14 | #include <TString.h> | |
15 | #include <TVector2.h> | |
16 | ||
17 | #include "AliMpSectorTypes.h" | |
18 | #include "AliMpDirection.h" | |
19 | ||
20 | class AliMpZone; | |
21 | class AliMpRow; | |
22 | class AliMpVRowSegment; | |
23 | class AliMpVMotif; | |
24 | class AliMpVPadIterator; | |
25 | class AliMpMotifMap; | |
26 | ||
27 | class AliMpSector : public TObject | |
28 | { | |
29 | public: | |
ffb47139 | 30 | AliMpSector(const TString& id, Int_t nofZones, Int_t nofRows, |
5f91c9e8 | 31 | AliMpDirection direction); |
32 | AliMpSector(); | |
33 | virtual ~AliMpSector(); | |
34 | ||
35 | // methods | |
36 | virtual AliMpVPadIterator* CreateIterator() const; | |
37 | void SetRowSegmentOffsets(); | |
38 | void Initialize(); | |
39 | void PrintGeometry() const; | |
40 | ||
41 | // find methods | |
42 | AliMpRow* FindRow(const TVector2& position) const; | |
43 | AliMpVMotif* FindMotif(const TVector2& position) const; | |
44 | Int_t FindMotifPositionId(const TVector2& position) const; | |
45 | ||
46 | AliMpRow* FindRow(Int_t motifPositionId) const; | |
47 | AliMpVRowSegment* FindRowSegment(Int_t motifPositionId) const; | |
48 | TVector2 FindPosition(Int_t motifPositionId) const; | |
49 | ||
50 | AliMpZone* FindZone(const TVector2& padDimensions) const; | |
51 | ||
52 | // geometry | |
53 | TVector2 Position() const; | |
54 | TVector2 Dimensions() const; | |
55 | ||
56 | // get methods | |
57 | Int_t GetNofZones() const; | |
58 | AliMpZone* GetZone(Int_t i) const; | |
59 | Int_t GetNofRows() const; | |
60 | AliMpRow* GetRow(Int_t i) const; | |
61 | AliMpDirection GetDirection() const; | |
62 | TVector2 GetMinPadDimensions() const; | |
63 | AliMpMotifMap* GetMotifMap() const; | |
64 | ||
65 | private: | |
66 | // methods | |
67 | AliMpVRowSegment* FindRowSegment(const TVector2& position) const; | |
68 | void SetRowOffsets(); | |
69 | void SetMotifPositions(); | |
70 | void SetGlobalIndices(); | |
71 | void SetMinPadDimensions(); | |
72 | ||
73 | // data members | |
74 | TString fID; // sector ID | |
75 | TVector2 fOffset; // sector position | |
76 | ZoneVector fZones; // zones | |
77 | RowVector fRows; // rows | |
78 | AliMpMotifMap* fMotifMap; // motif map | |
79 | AliMpDirection fDirection;// the direction of constant pad size | |
80 | TVector2 fMinPadDimensions; // minimal pad dimensions | |
81 | ||
82 | ClassDef(AliMpSector,1) //Sector | |
83 | }; | |
84 | ||
85 | // inline functions | |
86 | ||
87 | inline AliMpDirection AliMpSector::GetDirection() const | |
88 | { return fDirection; } | |
89 | ||
90 | inline TVector2 AliMpSector::GetMinPadDimensions() const | |
91 | { return fMinPadDimensions; } | |
92 | ||
93 | inline AliMpMotifMap* AliMpSector::GetMotifMap() const | |
94 | { return fMotifMap; } | |
95 | ||
96 | #endif //ALI_MP_SECTOR_H | |
97 |