1 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2 * See cxx source for full Copyright notice */
5 // $MpId: AliMpDDLStore.h,v 1.6 2006/05/24 13:58:16 ivana Exp $
7 /// \ingroup management
8 /// \class AliMpDDLStore
9 /// \brief The top container class for DDLs, det elements and bus patched
11 /// It provides acces to DDL, det element and bus patches objects
12 /// via various characteristics.
14 /// \author Ivana Hrivnacova, IPN Orsay;
15 /// Christian Finck, SUBATECH Nantes
17 #ifndef ALI_MP_DDL_STORE_H
18 #define ALI_MP_DDL_STORE_H
21 #include <TObjArray.h>
24 #include "AliMpExMap.h"
25 #include "AliMpIntPair.h"
28 class AliMpDetElement;
33 class AliMpDDLStore : public TObject {
36 AliMpDDLStore(TRootIOCtor* /*ioCtor*/);
37 virtual ~AliMpDDLStore();
39 // static access method
40 static AliMpDDLStore* Instance();
43 AliMpDDL* GetDDL(Int_t ddlId, Bool_t warn = true) const;
44 AliMpDetElement* GetDetElement(Int_t detElemId, Bool_t warn = true) const;
45 AliMpBusPatch* GetBusPatch(Int_t busPatchId, Bool_t warn = true) const;
47 Int_t GetDEfromBus(Int_t busPatchId) const;
48 Int_t GetDDLfromBus(Int_t busPatchId) const;
49 Int_t GetBusPatchId(Int_t detElemId, Int_t manuId) const;
52 AliMpIntPair GetDetElemIdManu(Int_t manuSerial) const;
56 AliMpDDLStore(const AliMpDDLStore& rhs);
57 AliMpDDLStore& operator=(const AliMpDDLStore& rhs);
60 Int_t GetManuListIndex(Int_t detElemId) const;
61 Int_t GetBusPatchIndex(Int_t detElemId, Int_t manuId) const;
65 // static data members
66 static AliMpDDLStore* fgInstance; ///< Singleton instance
67 static const Int_t fgkNofDDLs; ///< Total number of DDLs
70 TObjArray fDDLs; ///< Array of DDL objects
71 AliMpDEStore* fDetElements; ///< Detection element store
72 AliMpExMap fBusPatches; ///< The map of bus patches per their IDs
73 TArrayI fManuList12[16]; ///< Arrays of 1st manu in bus
75 ClassDef(AliMpDDLStore,1) // The manager class for definition of detection element types
78 #endif //ALI_MP_DDL_STORE_H