TRWLock
class description - source file - inheritance tree
public:
TRWLock TRWLock()
TRWLock TRWLock(TRWLock&)
virtual void ~TRWLock()
static TClass* Class()
virtual TClass* IsA() const
Int_t ReadLock()
Int_t ReadUnLock()
virtual void ShowMembers(TMemberInspector& insp, char* parent)
virtual void Streamer(TBuffer& b)
Int_t WriteLock()
Int_t WriteUnLock()
private:
Int_t fReaders
Int_t fWriters
TMutex fMutex
TCondition fLockFree
TRWLock
This class implements a reader/writer lock. A rwlock allows
a resource to be accessed by multiple reader threads but only
one writer thread.
TRWLock() : fLockFree(&fMutex)
Create reader/write lock.
Int_t ReadLock()
Obtain a reader lock. Returns always 0.
Int_t ReadUnLock()
Unlock reader lock. Returns -1 if thread was not locked,
0 if everything ok.
Int_t WriteLock()
Obtain a writer lock. Returns always 0.
Int_t WriteUnLock()
Unlock writer lock. Returns -1 if thread was not locked,
0 if everything ok.
Inline Functions
TClass* Class()
TClass* IsA() const
void ShowMembers(TMemberInspector& insp, char* parent)
void Streamer(TBuffer& b)
TRWLock TRWLock(TRWLock&)
void ~TRWLock()
Author: Fons Rademakers 04/01/2000
Last update: root/thread:$Name: $:$Id: TRWLock.cxx,v 1.1.1.1 2000/05/16 17:00:48 rdm Exp $
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
ROOT page - Class index - Top of the page
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.