BearParser
Portable Executable parsing library (from PE-bear)
Toggle main menu visibility
Main Page
Namespaces
Namespace List
Namespace Members
All
Functions
Enumerations
Enumerator
Classes
Class List
Class Index
Class Hierarchy
Class Members
All
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
x
z
~
Functions
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
~
Variables
a
b
c
d
e
f
i
l
m
n
o
p
r
s
t
w
x
Enumerations
a
d
e
f
l
o
r
s
t
w
Enumerator
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
z
Related Symbols
b
d
e
i
l
p
r
s
Files
File List
File Members
All
_
a
b
d
f
g
i
l
m
o
p
r
s
t
u
Functions
Variables
Typedefs
Macros
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Loading...
Searching...
No Matches
parser
include
bearparser
WatchedLocker.h
Go to the documentation of this file.
1
#pragma once
2
3
#include <iostream>
4
#include <QtCore>
5
6
7
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
8
class
WatchedLocker
:
public
QMutexLocker<QMutex> {
9
#else
10
class
WatchedLocker
:
public
QMutexLocker {
11
#endif
12
public
:
13
WatchedLocker
(QMutex *mutex,
bool
show =
false
,
const
char
*func =
nullptr
)
14
: QMutexLocker(mutex),
showLock
(show)
15
{
16
if
(func)
funcName
= func;
17
if
(
showLock
) {
18
std::cout << __FUNCTION__;
19
if
(
funcName
.length()) {
20
std::cout <<
" : "
<<
funcName
;
21
}
22
std::cout << std::endl;
23
}
24
}
13
WatchedLocker
(QMutex *mutex,
bool
show =
false
,
const
char
*func =
nullptr
) {
…
}
25
26
~WatchedLocker
()
27
{
28
if
(
showLock
) {
29
std::cout << __FUNCTION__;
30
if
(
funcName
.length()) {
31
std::cout <<
" : "
<<
funcName
;
32
}
33
std::cout << std::endl;
34
}
35
}
26
~WatchedLocker
() {
…
}
36
37
protected
:
38
std::string
funcName
;
39
bool
showLock
;
40
};
8
class
WatchedLocker
:
public
QMutexLocker<QMutex> {
…
};
WatchedLocker
Definition
WatchedLocker.h:8
WatchedLocker::showLock
bool showLock
Definition
WatchedLocker.h:39
WatchedLocker::funcName
std::string funcName
Definition
WatchedLocker.h:38
WatchedLocker::WatchedLocker
WatchedLocker(QMutex *mutex, bool show=false, const char *func=nullptr)
Definition
WatchedLocker.h:13
WatchedLocker::~WatchedLocker
~WatchedLocker()
Definition
WatchedLocker.h:26
Generated by
1.12.0