Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

TGo4ThreadManager.h

Go to the documentation of this file.
00001 //-------------------------------------------------------------
00002 //        Go4 Release Package v3.04-01 (build 30401)
00003 //                      28-November-2008
00004 //---------------------------------------------------------------
00005 //   The GSI Online Offline Object Oriented (Go4) Project
00006 //   Experiment Data Processing at EE 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 TGo4ThreadManager_H
00017 #define TGo4ThreadManager_H
00018 
00019 #include "TNamed.h"
00020 
00021 class TGo4ThreadHandler;
00022 class TGo4AppControlTimer;
00023 
00033 class TGo4ThreadManager : public TNamed {
00034 
00035    public:
00036       TGo4ThreadManager(const TGo4ThreadManager &right);
00037 
00042       TGo4ThreadManager (const char* name, Bool_t blockingmode = kTRUE, Bool_t autostart = kTRUE, Bool_t autocreate = kTRUE);
00043 
00044       virtual ~TGo4ThreadManager();
00045 
00048       void SetTimer(TGo4AppControlTimer* ctrltimer) { fxBlocker=ctrltimer; }
00049 
00051       TGo4ThreadHandler* GetWorkHandler() const { return fxWorkHandler; }
00052 
00054       Bool_t BlockApp();
00055 
00062       Bool_t UnBlockApp(Int_t mode = 0);
00063 
00064       virtual Int_t Initialization();
00065 
00066       Bool_t IsInitDone() const { return fbInitDone; }
00067 
00069       Bool_t IsTerminating () const { return fbTerminating; }
00070 
00071       Bool_t IsTerminateApp() const { return fbTerminateApplication; }
00072 
00074       Bool_t IsAppBlocking() const { return fbAppBlocking; }
00075 
00081       void Launch ();
00082 
00086       virtual void Terminate (Bool_t termapp=kTRUE);
00087 
00089       virtual void TerminateFast();
00090 
00092       static const Long_t fglTIMERPERIOD;
00093 
00095       enum { fguTEXTLENGTH = 256 };
00096 
00097    protected:
00098 
00100       Bool_t fbInitDone;
00101 
00103       Bool_t fbTerminating;
00104 
00107       Bool_t fbTerminateApplication;
00108 
00112       Bool_t fbAppBlocking;
00113 
00116       Bool_t fbAutoCreate;
00117 
00121       Bool_t fbAutoStart;
00122 
00127       TGo4AppControlTimer *fxBlocker; 
00128 
00133       TGo4ThreadHandler *fxWorkHandler;  
00134 
00135   private:
00136       TGo4ThreadManager();
00137 
00138    ClassDef(TGo4ThreadManager,1)
00139 };
00140 
00141 #endif
00142 
00143 //----------------------------END OF GO4 SOURCE FILE ---------------------

Generated on Fri Nov 28 12:59:31 2008 for Go4-v3.04-1 by  doxygen 1.4.2