]>
Commit | Line | Data |
---|---|---|
9e1a0ddb | 1 | #ifndef ALICONFIG_H |
2 | #define ALICONFIG_H | |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
4 | * See cxx source for full Copyright notice */ | |
5 | ||
6 | /* $Id$ */ | |
9e1a0ddb | 7 | |
e191bb57 | 8 | // |
9 | // Class to name the folders | |
10 | // This class contains | |
11 | // the names of the top level folders | |
12 | // | |
13 | ||
8b2d7c39 | 14 | // |
15 | // Class to name the folders | |
16 | // This class contains | |
17 | // the names of the top level folders | |
18 | // | |
19 | ||
88cb7938 | 20 | #include <TNamed.h> |
b16a1b1e | 21 | class TDatabasePDG; |
22 | class TFolder; | |
23 | class TString; | |
98490ea9 | 24 | class TVirtualMC; |
b16a1b1e | 25 | |
26 | class AliConfig; | |
27 | class AliDetector; | |
9e1a0ddb | 28 | class AliGenerator; |
29 | class AliModule; | |
9e1a0ddb | 30 | |
31 | class AliConfig : public TNamed { | |
7e90ff59 | 32 | |
33 | public: | |
88cb7938 | 34 | |
88cb7938 | 35 | virtual ~ AliConfig (); |
36 | ||
37 | void Add(TDatabasePDG *pdg); | |
88cb7938 | 38 | |
39 | void Add(AliGenerator *generator,const char* eventfolder = fgkDefaultEventFolderName); | |
40 | void Add (TVirtualMC *mc,const char* eventfolder = fgkDefaultEventFolderName); | |
41 | void Add (AliModule *module,const char* eventfolder = fgkDefaultEventFolderName); | |
42 | void Add (AliDetector *detector,const char* eventfolder = fgkDefaultEventFolderName); | |
43 | ||
44 | Int_t AddDetector(const char* evntfoldername,const char *name, const char* title); | |
45 | Int_t AddDetector(TFolder* evntfolder,const char *name, const char* title); | |
7e90ff59 | 46 | |
88cb7938 | 47 | Int_t CreateDetectorFolders(const char* evntfoldername,const char *name, const char* title);//Used by AliRunGetter |
48 | Int_t CreateDetectorFolders(TFolder* evntfolder,const char *name, const char* title);//Used by AliRunGetter | |
7e90ff59 | 49 | |
88cb7938 | 50 | static AliConfig* Instance(); |
7e90ff59 | 51 | |
88cb7938 | 52 | TFolder* BuildEventFolder(const char* name,const char* tilte); |
53 | ||
54 | TFolder* GetTopFolder(){return fTopFolder;} | |
88cb7938 | 55 | TFolder* GetConstFolder(){return fConstFolder;} |
56 | ||
57 | static const TString& GetModulesFolderName(){return fgkModuleFolderName;} | |
e191bb57 | 58 | static const TString& GetDefaultEventFolderName() |
59 | {return fgkDefaultEventFolderName;} | |
f21fc003 | 60 | |
d0d4a6b3 | 61 | const TString& GetDataFolderName() const;//returns name of data folder |
e191bb57 | 62 | |
63 | private: | |
cb5b8b21 | 64 | AliConfig(const AliConfig&); // Not implemented |
65 | AliConfig& operator=(const AliConfig&); // Not implemented | |
66 | AliConfig(); // Not implemented | |
67 | AliConfig(const char * name, const char * title ); | |
68 | ||
88cb7938 | 69 | static const TString fgkTopFolderName; //name of top AliRoot folder |
70 | ||
d0d4a6b3 | 71 | static const TString fgkDefaultEventFolderName; //name of event folder |
d0d4a6b3 | 72 | static const TString fgkConstantsFolderName; //name of constants folder |
73 | ||
74 | static const TString fgkDataFolderName; //name of data folde | |
75 | static const TString fgkConditionsFolderName; //name of conditions folder | |
76 | static const TString fgkConfigurationFolderName;//name of configuration foolder | |
77 | static const TString fgkHeaderFolderName; //name of header folder | |
f21fc003 | 78 | |
d0d4a6b3 | 79 | static const TString fgkCalibrationFolderName; //name of calibration folder |
80 | static const TString fgkAligmentFolderName; //name of alignment folder | |
d0d4a6b3 | 81 | |
82 | static const TString fgkFieldFolderName; //name of magn.field folder | |
83 | static const TString fgkGeneratorsFolderName; //name of generator folder | |
84 | static const TString fgkVirtualMCFolderName; //name of virtual MC folder | |
85 | ||
d0d4a6b3 | 86 | void AddInFolder (const char * dir, TObject *obj); |
d0d4a6b3 | 87 | Int_t AddSubFolder(TFolder* topfolder, const char* infoler, //helper method |
88 | const char* newfoldname, const char* newfoldtitle); | |
89 | TObject* FindInFolder (const char *dir, const char *name); | |
90 | ||
91 | // folders | |
92 | TFolder* fTopFolder; //pointer to top folder | |
d0d4a6b3 | 93 | TFolder* fConstFolder; //pointer to constants folder |
94 | ||
95 | static const TString fgkPDGFolderName; //name of PDG folder | |
96 | static const TString fgkGeneratorFolderName; //name of generator name | |
97 | static const TString fgkMCFolderName; //name of MC folder | |
98 | static const TString fgkModuleFolderName; //name of module folder | |
99 | ||
d0d4a6b3 | 100 | TString *fDetectorFolder;//!array with names for detector folders (where detector is going to be put) |
101 | ||
102 | static AliConfig* fgInstance; //pointer to the AliConfig instance | |
103 | ||
88cb7938 | 104 | |
f21fc003 | 105 | ClassDef(AliConfig,3) //Configuration class for AliRun |
9e1a0ddb | 106 | }; // end class AliConfig |
107 | ||
108 | #endif |