OpenDDS
Snapshot(2023/04/28-20:55)
|
Holds and distributes locks to be used for locking ACE_Data_Blocks. Currently it does not require returning the locks. More...
#include <DataBlockLockPool.h>
Public Types | |
typedef ACE_Lock_Adapter< ACE_Thread_Mutex > | DataBlockLock |
Public Member Functions | |
DataBlockLockPool (unsigned long size) | |
~DataBlockLockPool () | |
DataBlockLock * | get_lock () |
Private Types | |
typedef ACE_Array< DataBlockLock > | Pool |
Private Attributes | |
Pool | pool_ |
const unsigned long | size_ |
OpenDDS::DCPS::Atomic< unsigned long > | iterator_ |
Counter used to track which lock to give out next (modulus size_) More... | |
Holds and distributes locks to be used for locking ACE_Data_Blocks. Currently it does not require returning the locks.
: The lock returned is not guaranteed to be unique.
: This class is thread safe.
Definition at line 30 of file DataBlockLockPool.h.
Definition at line 32 of file DataBlockLockPool.h.
|
private |
Definition at line 49 of file DataBlockLockPool.h.
|
inline |
Definition at line 34 of file DataBlockLockPool.h.
|
inline |
Definition at line 41 of file DataBlockLockPool.h.
|
inline |
Definition at line 43 of file DataBlockLockPool.h.
References size_.
Referenced by OpenDDS::DCPS::RtpsUdpDataLink::alloc_msgblock(), and OpenDDS::DCPS::TransportSendStrategy::prepare_packet().
|
private |
Counter used to track which lock to give out next (modulus size_)
Definition at line 54 of file DataBlockLockPool.h.
|
private |
Definition at line 51 of file DataBlockLockPool.h.
|
private |
Definition at line 52 of file DataBlockLockPool.h.