00001 //--------------------------------------------------------------- 00002 // Go4 Release Package v2.10-5 (build 21005) 00003 // 03-Nov-2005 00004 //--------------------------------------------------------------- 00005 // The GSI Online Offline Object Oriented (Go4) Project 00006 // Experiment Data Processing at DVEE department, GSI 00007 //--------------------------------------------------------------- 00008 // 00009 //Copyright (C) 2000- Gesellschaft f. Schwerionenforschung, GSI 00010 // Planckstr. 1, 64291 Darmstadt, Germany 00011 //Contact: http://go4.gsi.de 00012 //---------------------------------------------------------------- 00013 //This software can be used under the license agreements as stated 00014 //in Go4License.txt file which is part of the distribution. 00015 //---------------------------------------------------------------- 00016 #ifndef TGO4ANALYSISSTEPMANAGER_H 00017 #define TGO4ANALYSISSTEPMANAGER_H 00018 00019 #include "TNamed.h" 00020 #include "TObjArray.h" 00021 #include "TFolder.h" 00022 #include "TList.h" 00023 #include "TThread.h" 00024 #include "TH1.h" 00025 #include "TTree.h" 00026 00027 #include "Go4ThreadManager/TGo4LockGuard.h" 00028 #include "Go4StatusBase/TGo4ObjectStatus.h" 00029 #include "Go4StatusBase/TGo4BranchStatus.h" 00030 #include "Go4Event/TGo4EventDataIndex.h" 00031 #include "Go4ConditionsBase/TGo4Condition.h" 00032 #include "Go4DynamicList/TGo4DynamicList.h" 00033 #include "Go4DynamicList/TGo4DynamicListStatus.h" 00034 #include "Go4DynamicList/TGo4TreeHistogramEntry.h" 00035 #include "Go4EventServer/TGo4MainTree.h" 00036 #include "Go4Analysis/TGo4AnalysisStep.h" 00037 #include "Go4StatusAnalysis/TGo4TreeStructure.h" 00038 00039 class TGo4EventProcessorParameter; 00040 class TGo4EventSourceParameter; 00041 class TGo4EventStoreParameter; 00042 class TGo4EventElement; 00043 class TGo4AnalysisStep; 00044 class TIterator; 00045 class TMutex; 00046 class TObjArray; 00047 class TFolder; 00048 00055 class TGo4AnalysisStepManager : public TNamed { 00056 public: 00065 Int_t ProcessAnalysisSteps(); 00069 TGo4AnalysisStep* GetAnalysisStep(const char* name); 00079 Bool_t AddAnalysisStep(TGo4AnalysisStep* next); 00080 00081 00082 00083 ~TGo4AnalysisStepManager(); 00084 00085 TGo4AnalysisStepManager(); 00086 00087 TGo4AnalysisStepManager(const Text_t* name); 00088 00094 void CloseAnalysis(); 00095 00101 virtual Bool_t InitEventClasses(); 00102 00106 void UpdateStatus(TGo4AnalysisStatus* state); 00107 00111 void SetStatus(TGo4AnalysisStatus * state); 00112 00116 void AutoSave(); 00117 00123 Bool_t SetFirstStep(const Text_t* name); 00124 00131 Bool_t SetLastStep(const Text_t* name); 00132 00145 Bool_t SetStepStorage(const Text_t* name, Bool_t on); 00146 00152 Bool_t NewStepStore(const Text_t * name, TGo4EventStoreParameter* par); 00153 00159 Bool_t NewStepSource(const Text_t * name, TGo4EventSourceParameter * par); 00160 00166 Bool_t NewStepProcessor(const Text_t * name, TGo4EventProcessorParameter * par); 00167 00174 Int_t Store(const Text_t * name, TGo4Parameter* obj); 00175 00182 Int_t Store(const Text_t * name, TGo4Condition* con); 00183 00190 Int_t Store(const Text_t * name, TGo4Fitter* fit); 00191 00198 Int_t Store(const Text_t * name, TFolder* folder); 00199 00206 TGo4EventElement* GetInputEvent(const char* stepname); 00207 00215 TGo4EventElement* GetInputEvent(Int_t stepindex); 00216 00223 TGo4EventElement* GetOutputEvent(const char* stepname); 00224 00234 TGo4EventElement* GetOutputEvent(Int_t stepindex); 00235 00241 TGo4EventElement* GetOutputEvent() { return fxOutputEvent; } 00242 00243 void SetOutputEvent(TGo4EventElement * event) { fxOutputEvent=event; } 00244 00245 Int_t IsErrorStopEnabled() 00246 { 00247 return kTRUE; // workaraound, to be removed later!!! JA 00248 if(fxCurrentStep) 00249 return fxCurrentStep->IsErrorStopEnabled(); 00250 else 00251 return kTRUE; 00252 } 00253 00254 void SetStepChecking(Bool_t on=kTRUE) { fbStepCheckingMode=on; } 00255 00256 Bool_t IsStepChecking() { return fbStepCheckingMode; } 00257 00258 private: 00259 00264 TObjArray* fxStepList; 00265 00269 TMutex * fxStepMutex; 00270 00274 TIterator* fxStepIterator; 00275 00281 Int_t fiFirstStepIndex; 00282 00289 Int_t fiLastStepIndex; 00290 00295 Int_t fiCurrentStepIndex; 00296 00303 Bool_t fbStepCheckingMode; 00304 00307 TGo4AnalysisStep * fxCurrentStep; 00308 00313 TGo4EventElement* fxOutputEvent; 00314 00315 }; 00316 00317 #endif //TGO4ANALYSISSTEPMANAGER_H 00318 00319 //----------------------------END OF GO4 SOURCE FILE ---------------------