Qt 4.8
Public Functions | Properties | List of all members
QLockHandle Class Reference

#include <qlock_p.h>

Public Functions

void lock (QLock::Type type)
 
bool locked () const
 
 QLockHandle (QLock *l, QLock::Type type)
 
void unlock ()
 
 ~QLockHandle ()
 

Properties

QLockqlock
 

Detailed Description

Definition at line 84 of file qlock_p.h.

Constructors and Destructors

◆ QLockHandle()

QLockHandle::QLockHandle ( QLock l,
QLock::Type  type 
)
inline

Definition at line 87 of file qlock_p.h.

87 : qlock(l) { qlock->lock(type); }
int type
Definition: qmetatype.cpp:239
QLock * qlock
Definition: qlock_p.h:95
void lock(Type type)
Locks the semaphore with a lock of type t.
Definition: qlock.cpp:285

◆ ~QLockHandle()

QLockHandle::~QLockHandle ( )
inline

Definition at line 88 of file qlock_p.h.

88 { if (locked()) qlock->unlock(); }
bool locked() const
Definition: qlock_p.h:92
void unlock()
Unlocks the semaphore.
Definition: qlock.cpp:345
QLock * qlock
Definition: qlock_p.h:95

Functions

◆ lock()

void QLockHandle::lock ( QLock::Type  type)
inline

Definition at line 90 of file qlock_p.h.

90 { qlock->lock(type); }
int type
Definition: qmetatype.cpp:239
QLock * qlock
Definition: qlock_p.h:95
void lock(Type type)
Locks the semaphore with a lock of type t.
Definition: qlock.cpp:285

◆ locked()

bool QLockHandle::locked ( ) const
inline

Definition at line 92 of file qlock_p.h.

92 { return qlock->locked(); }
bool locked() const
Returns true if the lock is currently held by the current process; otherwise returns false...
Definition: qlock.cpp:391
QLock * qlock
Definition: qlock_p.h:95

◆ unlock()

void QLockHandle::unlock ( )
inline

Definition at line 91 of file qlock_p.h.

91 { qlock->unlock(); }
void unlock()
Unlocks the semaphore.
Definition: qlock.cpp:345
QLock * qlock
Definition: qlock_p.h:95

Properties

◆ qlock

QLock* QLockHandle::qlock
private

Definition at line 95 of file qlock_p.h.


The documentation for this class was generated from the following file: