sbAutoWriteLock Class Reference

#include <sbAutoRWLock.h>

Public Member Functions

 sbAutoWriteLock (PRRWLock *aLock)
 
 ~sbAutoWriteLock (void)
 
void lock ()
 
void unlock ()
 

Detailed Description

sbAutoWriteLock Stack-based write locking object for PRRWLock.

Definition at line 129 of file sbAutoRWLock.h.

Constructor & Destructor Documentation

sbAutoWriteLock::sbAutoWriteLock ( PRRWLock *  aLock)
inline

Constructor The constructor aquires the given lock for writing. The destructor releases the lock.

Parameters
aLockA valid PRRWLock* returned from the NSPR's PR_NewRWLock() function.

Definition at line 159 of file sbAutoRWLock.h.

sbAutoWriteLock::~sbAutoWriteLock ( void  )
inline

Definition at line 169 of file sbAutoRWLock.h.

Member Function Documentation

void sbAutoWriteLock::lock ( )
inline

lock Client may call this to reaquire the given lock. Take special note that attempting to aquire a locked lock will hang or crash.

Definition at line 179 of file sbAutoRWLock.h.

void sbAutoWriteLock::unlock ( )
inline

unlock Client may call this to release the given lock. Take special note unlocking an unlocked lock has undefined results.

Definition at line 191 of file sbAutoRWLock.h.


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