Logo ROOT   6.12/07
Reference Guide
TThreadFactory.h
Go to the documentation of this file.
1 // @(#)root/thread:$Id$
2 // Author: Fons Rademakers 01/07/97
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 
13 #ifndef ROOT_TThreadFactory
14 #define ROOT_TThreadFactory
15 
16 //////////////////////////////////////////////////////////////////////////
17 // //
18 // TThreadFactory //
19 // //
20 // This ABC is a factory for thread components. Depending on which //
21 // factory is active one gets either Posix or Win32 threads. //
22 // //
23 //////////////////////////////////////////////////////////////////////////
24 
25 #include "TNamed.h"
26 
27 class TMutexImp;
28 class TConditionImp;
29 class TThreadImp;
30 class TThread;
31 
32 class TThreadFactory : public TNamed {
33 
34 public:
35  TThreadFactory(const char *name = "Unknown", const char *title = "Unknown Thread Factory");
36  virtual ~TThreadFactory() { }
37 
38  virtual TMutexImp *CreateMutexImp(Bool_t recursive) = 0;
40  virtual TThreadImp *CreateThreadImp() = 0;
41 
42  ClassDef(TThreadFactory,0) // Thread factory ABC
43 };
44 
46 
47 #endif
48 
49 
50 
TThreadFactory(const char *name="Unknown", const char *title="Unknown Thread Factory")
TThreadFactory ctor only called by derived classes.
auto * m
Definition: textangle.C:8
bool Bool_t
Definition: RtypesCore.h:59
R__EXTERN TThreadFactory * gThreadFactory
virtual TThreadImp * CreateThreadImp()=0
#define ClassDef(name, id)
Definition: Rtypes.h:320
The TNamed class is the base class for all named ROOT classes.
Definition: TNamed.h:29
virtual TMutexImp * CreateMutexImp(Bool_t recursive)=0
virtual ~TThreadFactory()
virtual TConditionImp * CreateConditionImp(TMutexImp *m)=0
#define R__EXTERN
Definition: DllImport.h:27
char name[80]
Definition: TGX11.cxx:109