ROOT
master
Reference Guide
Loading...
Searching...
No Matches
TWin32ThreadFactory.cxx
Go to the documentation of this file.
1
// @(#)root/thread:$Id$
2
// Author: Bertrand Bellenot 20/10/2004
3
4
/*************************************************************************
5
* Copyright (C) 1995-2004, 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
// //
14
// TWin32ThreadFactory //
15
// //
16
// This is a factory for Win32 thread components. //
17
// //
18
//////////////////////////////////////////////////////////////////////////
19
20
#include "
TWin32ThreadFactory.h
"
21
#include "
TWin32Mutex.h
"
22
#include "
TWin32Condition.h
"
23
#include "
TWin32Thread.h
"
24
25
// Force creation of TWin32ThreadFactory when shared library will be loaded
26
// (don't explicitly create a TWin32ThreadFactory).
27
static
TWin32ThreadFactory
gWin32ThreadFactoryCreator
;
28
29
ClassImp
(
TWin32ThreadFactory
);
30
31
////////////////////////////////////////////////////////////////////////////////
32
/// Create Win32 thread factory. Also sets global gThreadFactory to this.
33
34
TWin32ThreadFactory::TWin32ThreadFactory
(
const
char
*
name
,
const
char
*title) :
35
TThreadFactory
(
name
, title)
36
{
37
gThreadFactory
=
this
;
38
}
39
40
////////////////////////////////////////////////////////////////////////////////
41
/// Return a Win32 Mutex.
42
43
TMutexImp
*
TWin32ThreadFactory::CreateMutexImp
(
Bool_t
recursive)
44
{
45
return
new
TWin32Mutex
(recursive);
46
}
47
48
////////////////////////////////////////////////////////////////////////////////
49
/// Return a Win32 thread.
50
51
TThreadImp
*
TWin32ThreadFactory::CreateThreadImp
()
52
{
53
return
new
TWin32Thread
;
54
}
55
56
////////////////////////////////////////////////////////////////////////////////
57
/// Return a Win32 condition variable.
58
59
TConditionImp
*
TWin32ThreadFactory::CreateConditionImp
(
TMutexImp
*
m
)
60
{
61
return
new
TWin32Condition
(
m
);
62
}
ClassImp
#define ClassImp(name)
Definition
Rtypes.h:382
name
char name[80]
Definition
TGX11.cxx:110
gThreadFactory
R__EXTERN TThreadFactory * gThreadFactory
Definition
TThreadFactory.h:45
TWin32Condition.h
TWin32Mutex.h
gWin32ThreadFactoryCreator
static TWin32ThreadFactory gWin32ThreadFactoryCreator
Definition
TWin32ThreadFactory.cxx:27
TWin32ThreadFactory.h
TWin32Thread.h
TConditionImp
Definition
TConditionImp.h:26
TMutexImp
Definition
TMutexImp.h:27
TThreadFactory
Definition
TThreadFactory.h:32
TThreadImp
Definition
TThreadImp.h:31
TWin32Condition
Definition
TWin32Condition.h:55
TWin32Mutex
Definition
TWin32Mutex.h:28
TWin32ThreadFactory
Definition
TWin32ThreadFactory.h:31
TWin32ThreadFactory::TWin32ThreadFactory
TWin32ThreadFactory(const char *name="Win32", const char *title="Win32 Thread Factory")
Create Win32 thread factory. Also sets global gThreadFactory to this.
Definition
TWin32ThreadFactory.cxx:34
TWin32ThreadFactory::CreateMutexImp
TMutexImp * CreateMutexImp(Bool_t recursive) override
Return a Win32 Mutex.
Definition
TWin32ThreadFactory.cxx:43
TWin32ThreadFactory::CreateThreadImp
TThreadImp * CreateThreadImp() override
Return a Win32 thread.
Definition
TWin32ThreadFactory.cxx:51
TWin32ThreadFactory::CreateConditionImp
TConditionImp * CreateConditionImp(TMutexImp *m) override
Return a Win32 condition variable.
Definition
TWin32ThreadFactory.cxx:59
TWin32Thread
Definition
TWin32Thread.h:30
bool
m
TMarker m
Definition
textangle.C:8
core
thread
src
TWin32ThreadFactory.cxx
ROOT master - Reference Guide Generated on Tue Dec 3 2024 09:32:45 (GVA Time) using Doxygen 1.9.8