OpenDDS
Snapshot(2023/04/07-19:43)
|
Queue class that provides a means to reset the underlying ACE_Allocator
.
More...
#include <DurabilityQueue.h>
Public Member Functions | |
DurabilityQueue (ACE_Allocator *allocator) | |
DurabilityQueue (DurabilityQueue< T > const &rhs) | |
~DurabilityQueue () | |
void | operator= (DurabilityQueue< T > const &rhs) |
void | set_allocator (ACE_Allocator *allocator) |
Reset allocator. More... | |
void | swap (DurabilityQueue< T > &rhs) |
typedef | OPENDDS_VECTOR (OPENDDS_STRING) fs_path_t |
![]() | |
ACE_Unbounded_Queue (ACE_Allocator *alloc=0) | |
ACE_Unbounded_Queue (const ACE_Unbounded_Queue< T > &) | |
void | operator= (const ACE_Unbounded_Queue< T > &) |
~ACE_Unbounded_Queue (void) | |
bool | is_empty (void) const |
bool | is_full (void) const |
int | enqueue_tail (const T &new_item) |
int | enqueue_head (const T &new_item) |
int | dequeue_head (T &item) |
void | reset (void) |
int | get (T *&item, size_t slot=0) const |
int | set (const T &item, size_t slot) |
size_t | size (void) const |
void | dump (void) const |
ACE_Unbounded_Queue_Iterator< T > | begin (void) |
ACE_Unbounded_Queue_Iterator< T > | end (void) |
Public Attributes | |
fs_path_t | fs_path_ |
![]() | |
ACE_ALLOC_HOOK_DECLARE | |
Additional Inherited Members | |
![]() | |
typedef ACE_Unbounded_Queue_Iterator< T > | ITERATOR |
typedef ACE_Unbounded_Queue_Const_Iterator< T > | CONST_ITERATOR |
![]() | |
void | delete_nodes (void) |
void | copy_nodes (const ACE_Unbounded_Queue< T > &) |
![]() | |
ACE_Node< T > * | head_ |
size_t | cur_size_ |
ACE_Allocator * | allocator_ |
Queue class that provides a means to reset the underlying ACE_Allocator
.
This class only exists to provide a means to reset the allocator used by the ACE_Unbounded_Queue
base class. It has a specific use case, namely to correctly support instances created by a persistent allocator. The allocator address may change between process runs, meaning the allocator address stored in the persistent ACE_Unbounded_Queue
instance will be invalid. Use the set_allocator()
method to reset the allocator address before performing any operations that will require use of the allocator (e.g. enqueuing new items).
Definition at line 38 of file DurabilityQueue.h.
|
inline |
Definition at line 41 of file DurabilityQueue.h.
|
inline |
Definition at line 45 of file DurabilityQueue.h.
References ACE_Unbounded_Queue< T >::delete_nodes(), ACE_Unbounded_Queue< T >::enqueue_tail(), ACE_Unbounded_Queue< T >::head_, and ACE_Node< T >::next_.
|
inline |
Definition at line 57 of file DurabilityQueue.h.
typedef OpenDDS::DCPS::DurabilityQueue< T >::OPENDDS_VECTOR | ( | OPENDDS_STRING | ) |
Referenced by OpenDDS::DCPS::DurabilityQueue< T >::swap().
|
inline |
Definition at line 59 of file DurabilityQueue.h.
References OpenDDS::DCPS::DurabilityQueue< T >::swap().
|
inline |
Reset allocator.
Definition at line 65 of file DurabilityQueue.h.
References ACE_Unbounded_Queue< T >::allocator_, and ACE_Allocator::instance().
|
inline |
Definition at line 72 of file DurabilityQueue.h.
References ACE_Unbounded_Queue< T >::allocator_, ACE_Unbounded_Queue< T >::cur_size_, OpenDDS::DCPS::DurabilityQueue< T >::fs_path_, ACE_Unbounded_Queue< T >::head_, OPENDDS_STRING, OpenDDS::DCPS::DurabilityQueue< T >::OPENDDS_VECTOR(), and OpenDDS::DCPS::swap().
Referenced by OpenDDS::DCPS::DurabilityQueue< T >::operator=().
fs_path_t OpenDDS::DCPS::DurabilityQueue< T >::fs_path_ |
Definition at line 81 of file DurabilityQueue.h.
Referenced by OpenDDS::DCPS::DurabilityQueue< T >::swap().