This class is similar to class ACE_Guard, though it acquires/releases a read lock automatically (naturally, the <ACE_LOCK> it is instantiated with must support the appropriate API).
More...
#include <Guard_T.h>
Public Member Functions |
| ACE_Read_Guard (ACE_LOCK &m) |
| Implicitly and automatically acquire a read lock.
|
| ACE_Read_Guard (ACE_LOCK &m, bool block) |
int | acquire_read (void) |
| Explicitly acquire the read lock.
|
int | acquire (void) |
| Explicitly acquire the read lock.
|
int | tryacquire_read (void) |
| Conditionally acquire the read lock (i.e., won't block).
|
int | tryacquire (void) |
| Conditionally acquire the read lock (i.e., won't block).
|
void | dump (void) const |
| Dump the state of an object.
|
| ACE_Guard (ACE_LOCK &l) |
| ACE_Guard (ACE_LOCK &l, bool block) |
| ACE_Guard (ACE_LOCK &l, bool block, int become_owner) |
| ~ACE_Guard (void) |
| Implicitly release the lock.
|
int | release (void) |
| Explicitly release the lock, but only if it is held!
|
void | disown (void) |
bool | locked (void) const |
int | remove (void) |
| Explicitly remove the lock.
|
Additional Inherited Members |
| ACE_Guard (ACE_LOCK *lock) |
| Helper, meant for subclass only.
|
ACE_LOCK * | lock_ |
| Pointer to the ACE_LOCK we're guarding.
|
int | owner_ |
| Keeps track of whether we acquired the lock or failed.
|
Detailed Description
template<class ACE_LOCK>
class ACE_Read_Guard< ACE_LOCK >
This class is similar to class ACE_Guard, though it acquires/releases a read lock automatically (naturally, the <ACE_LOCK> it is instantiated with must support the appropriate API).
- Warning
- See important "WARNING" in comments at top of ACE_Guard.
Constructor & Destructor Documentation
template<class ACE_LOCK >
Implicitly and automatically acquire a read lock.
template<class ACE_LOCK >
Implicitly and automatically acquire (or try to acquire) a read lock.
Member Function Documentation
template<class ACE_LOCK >
template<class ACE_LOCK >
Explicitly acquire the read lock.
template<class ACE_LOCK >
template<class ACE_LOCK >
template<class ACE_LOCK >
Conditionally acquire the read lock (i.e., won't block).
The documentation for this class was generated from the following files: