ost::ThreadLock(3) | Library Functions Manual | ost::ThreadLock(3) |
ost::ThreadLock - The ThreadLock class impliments a thread rwlock for optimal reader performance on systems which have rwlock support, and reverts to a simple mutex for those that do not.
#include <thread.h>
ThreadLock ()
Create a process shared thread lock object. virtual ~ThreadLock ()
Destroy a process shared thread lock object. void readLock (void)
Aquire a read lock for the current object. void writeLock (void)
Aquire a write lock for the current object. bool tryReadLock (void)
Attempt read lock for current object. bool tryWriteLock (void)
Attempt write lock for current object. void unlock (void)
Release any held locks.
The ThreadLock class impliments a thread rwlock for optimal reader performance on systems which have rwlock support, and reverts to a simple mutex for those that do not.
Author
Posix rwlock extension for protected access.
Create a process shared thread lock object.
Destroy a process shared thread lock object.
Aquire a read lock for the current object.
Referenced by ost::ReadLock::ReadLock().
Attempt read lock for current object.
Returns
Attempt write lock for current object.
Returns
Release any held locks.
Referenced by ost::ReadLock::~ReadLock(), and ost::WriteLock::~WriteLock().
Aquire a write lock for the current object.
Referenced by ost::WriteLock::WriteLock().
Generated automatically by Doxygen for GNU CommonC++ from the source code.
Sun Dec 27 2020 | GNU CommonC++ |