Dokumentation VDR

Main Page   Class Hierarchy   Alphabetical List   Data Structures   File List   Data Fields   Globals  

cThreadLock Class Reference

#include <thread.h>

Collaboration diagram for cThreadLock:

Collaboration graph

Detailed Description

Lock thread.

Definition at line 96 of file thread.h.

Public Methods

 cThreadLock (cThread *Thread=NULL)
 ~cThreadLock ()
bool Lock (cThread *Thread)

Private Attributes

bool locked

Constructor & Destructor Documentation

cThreadLock::cThreadLock cThread   Thread = NULL

Definition at line 249 of file thread.c.

References Lock(), locked, and thread.


Definition at line 256 of file thread.c.

References locked, thread, and cThread::Unlock().

Member Function Documentation

bool cThreadLock::Lock cThread   Thread

Definition at line 262 of file thread.c.

References cThread::Lock(), locked, and thread.

Referenced by cThreadLock().

Field Documentation

bool cThreadLock::locked [private]

Definition at line 107 of file thread.h.

Referenced by cThreadLock(), Lock(), and ~cThreadLock().

cThread* cThreadLock::thread [private]

cThreadLock can be used to easily set a lock in a thread and make absolutely sure that it will be unlocked when the block will be left. Several locks can be stacked, so a function that makes many calls to another function which uses cThreadLock may itself use a cThreadLock to make one longer lock instead of many short ones.

Definition at line 106 of file thread.h.

Referenced by cThreadLock(), Lock(), and ~cThreadLock().

The documentation for this class was generated from the following files:
Generated on Wed Feb 5 23:31:59 2003 for VDR by doxygen1.3-rc2