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

MainGo4ThreadManagerExample.cxx

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 // MainGo4ThreadManager.cxx:
00017 // This executable just creates one ThreadManager subclass.
00018 // example: TGo4TestThreadManager as user class
00019 // all runnables and threads are defined in ctor of TGo4TestThreadManager.
00020 // On calling theApp.Run(), the threads are started.
00021 // (J.Adamczewski, GSI)
00022 
00023 #include "Riostream.h"
00024 
00025 #include "TApplication.h"
00026 
00027 #include "TGo4Log.h"
00028 #include "TGo4TestThreadManager.h"
00029 
00030 int main(int argc, char **argv)
00031 {
00032    TApplication theApp("App", &argc, argv);
00033    TGo4Log::Instance(); // init logger object
00034    TGo4Log::SetIgnoreLevel(0); // set this to 1 to suppress detailed debug output
00035                                // set this to 2 to get warnings and errors only
00036                                // set this to 3 to get errors only
00037    TGo4Log::LogfileEnable(kFALSE); // will enable or disable logging all messages to file
00038    TGo4TestThreadManager* myManager = new TGo4TestThreadManager("MyTestEnvironment");
00039    cout << "Created thread manager "<< myManager->GetName()<< endl;
00040    theApp.Run();
00041    return 0;
00042 }
00043 
00044 //----------------------------END OF GO4 SOURCE FILE ---------------------

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