|
ACE 8.0.1
|
This is an adapter that allows applications to transparently combine the ACE_Lock abstract base class (which contains pure virtual methods) with any of the other concrete ACE synchronization classes (e.g., ACE_Mutex, ACE_Semaphore, ACE_RW_Mutex, etc.). More...
#include <Lock_Adapter_T.h>


Public Types | |
| typedef ACE_LOCKING_MECHANISM | ACE_LOCK |
Public Member Functions | |
| ACE_Lock_Adapter (ACE_LOCKING_MECHANISM &lock) | |
| Constructor. All locking requests will be forwarded to lock. | |
| ACE_Lock_Adapter () | |
| virtual | ~ACE_Lock_Adapter () |
| virtual int | acquire () |
| Block the thread until the lock is acquired. | |
| virtual int | tryacquire () |
| Conditionally acquire the lock (i.e., won't block). | |
| virtual int | release () |
| Release the lock. | |
| virtual int | acquire_read () |
| virtual int | acquire_write () |
| virtual int | tryacquire_read () |
| virtual int | tryacquire_write () |
| virtual int | tryacquire_write_upgrade () |
| virtual int | remove () |
| Explicitly destroy the lock. | |
Public Member Functions inherited from ACE_Lock | |
| ACE_Lock () | |
| CE needs a default constructor here. | |
| virtual | ~ACE_Lock ()=default |
| Noop virtual destructor. | |
Private Attributes | |
| ACE_LOCKING_MECHANISM * | lock_ |
| The concrete locking mechanism that all the methods delegate to. | |
| bool | delete_lock_ |
This is an adapter that allows applications to transparently combine the ACE_Lock abstract base class (which contains pure virtual methods) with any of the other concrete ACE synchronization classes (e.g., ACE_Mutex, ACE_Semaphore, ACE_RW_Mutex, etc.).
This class uses a form of the Adapter pattern.
| typedef ACE_LOCKING_MECHANISM ACE_Lock_Adapter< ACE_LOCKING_MECHANISM >::ACE_LOCK |
|
inline |
Constructor. All locking requests will be forwarded to lock.
|
inline |
Constructor. Since no lock is provided by the user, one will be created internally.
|
virtual |
Destructor. If lock_ was not passed in by the user, it will be deleted.
|
virtual |
Block the thread until the lock is acquired.
Implements ACE_Lock.
|
virtual |
|
virtual |
|
virtual |
Release the lock.
Implements ACE_Lock.
|
virtual |
Explicitly destroy the lock.
Implements ACE_Lock.
|
virtual |
Conditionally acquire the lock (i.e., won't block).
Implements ACE_Lock.
|
virtual |
|
virtual |
|
virtual |
|
private |
This flag keep track of whether we are responsible for deleting the lock
|
private |
The concrete locking mechanism that all the methods delegate to.