1 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2 * See cxx source for full Copyright notice */
5 // $MpId: AliMpDEStore.h,v 1.6 2006/05/24 13:58:16 ivana Exp $
7 /// \ingroup management
8 /// \class AliMpDEStore
9 /// \brief The container class for detection element objects
11 /// \author Ivana Hrivnacova, IPN Orsay;
12 /// Laurent Aphecetche, Christian Finck, SUBATECH Nantes
14 #ifndef ALI_MP_DE_STORE_H
15 #define ALI_MP_DE_STORE_H
20 #include "AliMpExMap.h"
21 #include "AliMpPlaneType.h"
22 #include "AliMpStationType.h"
23 #include "AliMpIntPair.h"
25 class AliMpDetElement;
28 class AliMpDEStore : public TObject {
30 friend class AliMpDEIterator;
33 AliMpDEStore(TRootIOCtor* /*ioCtor*/);
34 virtual ~AliMpDEStore();
36 // static access method
37 static AliMpDEStore* Instance(Bool_t warn = true);
38 static AliMpDEStore* ReadData(Bool_t warn = true);
41 AliMpDetElement* GetDetElement(Int_t detElemId, Bool_t warn = true) const;
42 AliMpDetElement* GetDetElement(const TString& detName, Bool_t warn = true) const;
44 AliMpIntPair GetDetElemIdManu(Int_t manuSerial) const;
49 AliMpDEStore(const AliMpDEStore& rhs);
51 AliMpDEStore& operator=(const AliMpDEStore& rhs);
54 Bool_t IsPlaneType(const TString& planeTypeName);
55 AliMp::PlaneType PlaneType(const TString& planeTypeName);
56 AliMp::StationType StationType(const TString& stationTypeName);
58 Bool_t ReadManuToSerialNbs(AliMpDetElement* detElement,
59 AliMp::StationType stationType);
60 Bool_t ReadDENames(AliMp::StationType stationType);
63 // static data members
64 static AliMpDEStore* fgInstance; ///< Singleton instance
65 static const char fgkCommentPrefix; ///< Comment prefix in DE names file
68 AliMpExMap fDetElements; ///< Map between DE Ids and DE objects
70 ClassDef(AliMpDEStore,1) // The manager class for definition of detection element types
73 #endif //ALI_MP_MANAGER_H