ROOT
master
Reference Guide
Loading...
Searching...
No Matches
TWin32Mutex.h
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
#ifndef ROOT_TWin32Mutex
13
#define ROOT_TWin32Mutex
14
15
16
//////////////////////////////////////////////////////////////////////////
17
// //
18
// TWin32Mutex //
19
// //
20
// This class provides an interface to the Win32 mutex routines. //
21
// //
22
//////////////////////////////////////////////////////////////////////////
23
24
#include "
TMutexImp.h
"
25
26
#include "
Windows4Root.h
"
27
28
class
TWin32Mutex
:
public
TMutexImp
{
29
30
friend
class
TWin32Condition
;
31
32
private
:
33
CRITICAL_SECTION
fCritSect
;
34
35
enum
EStatusBits
{
kIsRecursive
=
BIT
(14) };
36
37
public
:
38
TWin32Mutex
(
Bool_t
recursive=
kFALSE
);
39
virtual
~TWin32Mutex
();
40
41
Int_t
Lock
()
override
;
42
Int_t
UnLock
()
override
;
43
Int_t
TryLock
()
override
;
44
45
ClassDefOverride
(
TWin32Mutex
,0)
// Win32 mutex lock
46
};
47
48
#endif
Bool_t
bool Bool_t
Definition
RtypesCore.h:63
Int_t
int Int_t
Definition
RtypesCore.h:45
kFALSE
constexpr Bool_t kFALSE
Definition
RtypesCore.h:94
BIT
#define BIT(n)
Definition
Rtypes.h:90
ClassDefOverride
#define ClassDefOverride(name, id)
Definition
Rtypes.h:346
TMutexImp.h
Windows4Root.h
TMutexImp
Definition
TMutexImp.h:27
TWin32Condition
Definition
TWin32Condition.h:55
TWin32Mutex
Definition
TWin32Mutex.h:28
TWin32Mutex::Lock
Int_t Lock() override
Lock the mutex.
Definition
TWin32Mutex.cxx:48
TWin32Mutex::UnLock
Int_t UnLock() override
Unlock the mutex.
Definition
TWin32Mutex.cxx:67
TWin32Mutex::~TWin32Mutex
virtual ~TWin32Mutex()
TMutex dtor.
Definition
TWin32Mutex.cxx:40
TWin32Mutex::TryLock
Int_t TryLock() override
Try locking the mutex. Returns 0 if mutex can be locked.
Definition
TWin32Mutex.cxx:57
TWin32Mutex::EStatusBits
EStatusBits
Definition
TWin32Mutex.h:35
TWin32Mutex::kIsRecursive
@ kIsRecursive
Definition
TWin32Mutex.h:35
TWin32Mutex::fCritSect
CRITICAL_SECTION fCritSect
Definition
TWin32Mutex.h:33
core
thread
inc
TWin32Mutex.h
ROOT master - Reference Guide Generated on Thu Dec 19 2024 09:45:33 (GVA Time) using Doxygen 1.9.8