AliRoot Core  v5-06-30 (35d6c57)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliMpSegmentation.h
Go to the documentation of this file.
1 #ifndef ALI_MP_SEGMENTATION_H
2 #define ALI_MP_SEGMENTATION_H
3 
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5  * See cxx source for full Copyright notice */
6 
7 // $Id$
8 // $MpId: AliMpSegmentation.h,v 1.7 2006/05/24 13:58:16 ivana Exp $
9 
23 
24 #ifndef ROOT_TObject
25 # include <TObject.h>
26 #endif
27 
28 #ifndef ALI_MP_STRING_OBJ_MAP_H
29 # include "AliMpStringObjMap.h"
30 #endif
31 
32 #ifndef ALI_MP_EX_MAP_H
33 # include "AliMpExMap.h"
34 #endif
35 
36 #ifndef ALI_MP_CATHOD_TYPE_H
37 # include "AliMpCathodType.h"
38 #endif
39 
40 class AliMpDEStore;
41 class AliMpSegmentation;
42 class AliMpVSegmentation;
43 class AliMpSlatMotifMap;
44 class AliMpDataStreams;
45 class AliMpSector;
46 class AliMpSlat;
47 class AliMpTrigger;
48 class TRootIOCtor;
49 
50 using std::ofstream;
51 
52 class AliMpSegmentation : public TObject {
53 
54  public:
55  AliMpSegmentation(TRootIOCtor* ioCtor);
56  virtual ~AliMpSegmentation();
57 
58  // static methods
59  static AliMpSegmentation* Instance(Bool_t warn = true);
60  static AliMpSegmentation* ReadData(const AliMpDataStreams& dataStreams,
61  Bool_t warn = true);
62 
63  // methods
64 
65  //
66  // Access to segmentations
67  //
68 
70  Int_t detElemId, AliMp::CathodType cath,
71  Bool_t warn = true) const;
72 
74  Int_t detElemId, Int_t elCardID,
75  Bool_t warn = true) const;
76  //
77  // Access to sectors, slats, triggers
78  //
79 
80  const AliMpSector* GetSector(const AliMpVSegmentation* kSegmentation,
81  Bool_t warn = true) const;
82  const AliMpSector* GetSector(Int_t detElemId, AliMp::CathodType cath,
83  Bool_t warn = true) const;
84  const AliMpSector* GetSectorByElectronics(Int_t detElemId, Int_t elCardID,
85  Bool_t warn = true) const;
86 
87  const AliMpSlat* GetSlat(const AliMpVSegmentation* kSegmentation,
88  Bool_t warn = true) const;
89  const AliMpSlat* GetSlat(Int_t detElemId, AliMp::CathodType cath,
90  Bool_t warn = true) const;
91  const AliMpSlat* GetSlatByElectronics(Int_t detElemId, Int_t elCardID,
92  Bool_t warn = true) const;
93 
94  const AliMpTrigger* GetTrigger(const AliMpVSegmentation* kSegmentation,
95  Bool_t warn = true) const;
96  const AliMpTrigger* GetTrigger(Int_t detElemId, AliMp::CathodType cath,
97  Bool_t warn = true) const;
98  const AliMpTrigger* GetTriggerByElectronics(Int_t detElemId, Int_t elCardID,
99  Bool_t warn = true) const;
100 
101  private:
102  AliMpSegmentation(const AliMpDataStreams& dataStreams);
107 
109  const AliMpDataStreams& dataStreams,
110  Int_t detElemId, AliMp::CathodType cath);
111 
112 
113  AliMpExMap* FillElCardsMap(Int_t detElemId);
114 
115  // static data members
117 
118  // data members
123 
124  ClassDef(AliMpSegmentation,3) // The factory for building mapping segmentations
125 };
126 
127 #endif //ALI_MP_SEGMENTATION_H
128 
129 
130 
131 
132 
133 
134 
135 
136 
137 
138 
139 
140 
141 
142 
Singleton container class for mapping segmentations.
const AliMpVSegmentation * GetMpSegmentation(Int_t detElemId, AliMp::CathodType cath, Bool_t warn=true) const
The container class for detection element objects.
Definition: AliMpDEStore.h:29
AliMpSlatMotifMap * fSlatMotifMap
Map of motif, motifTypes to avoid duplications and allow proper deletion.
AliMpVSegmentation * CreateMpSegmentation(const AliMpDataStreams &dataStreams, Int_t detElemId, AliMp::CathodType cath)
static AliMpSegmentation * Instance(Bool_t warn=true)
AliMpSegmentation(TRootIOCtor *ioCtor)
const AliMpSlat * GetSlatByElectronics(Int_t detElemId, Int_t elCardID, Bool_t warn=true) const
AliMpSegmentation & operator=(const AliMpSegmentation &rhs)
Not implemented.
const AliMpSlat * GetSlat(const AliMpVSegmentation *kSegmentation, Bool_t warn=true) const
static AliMpSegmentation * ReadData(const AliMpDataStreams &dataStreams, Bool_t warn=true)
const AliMpVSegmentation * GetMpSegmentationByElectronics(Int_t detElemId, Int_t elCardID, Bool_t warn=true) const
A slat (building block of stations 3, 4 and 5)
Definition: AliMpSlat.h:51
A container to keep track of allocated motifs and motifTypes for slats (both St345 and trigger ones)...
A trigger slat.
Definition: AliMpTrigger.h:37
const AliMpSector * GetSector(const AliMpVSegmentation *kSegmentation, Bool_t warn=true) const
Substitutes map <string, TObject> which ALICE does not allow to use.
const AliMpSector * GetSectorByElectronics(Int_t detElemId, Int_t elCardID, Bool_t warn=true) const
AliMpExMap * FillElCardsMap(Int_t detElemId)
AliMpExMap fElCardsMap
Map of el. cards IDs to segmentations.
A sector (quadrant) of the MUON chamber of stations 1 and 2.
Definition: AliMpSector.h:34
The abstract base class for the segmentation.
AliMpStringObjMap fMpSegmentations
Map of mapping segmentations to DE seg names.
AliMpDEStore * fDetElements
Detection element store.
const AliMpTrigger * GetTrigger(const AliMpVSegmentation *kSegmentation, Bool_t warn=true) const
const AliMpTrigger * GetTriggerByElectronics(Int_t detElemId, Int_t elCardID, Bool_t warn=true) const
static AliMpSegmentation * fgInstance
Singleton instance.
Helper class making Root persistent TExMap.
Definition: AliMpExMap.h:28
Mapping data streams provider.