#include <alloc_smart_pointer.hh>
Inheritance diagram for mpcl::memory::TAllocSmartPointer< TItem, TAllocator >:
Public Types | |
typedef const TItem * | const_pointer |
typedef const TItem & | const_reference |
typedef TAllocator< TItem > | item_allocator |
Item allocator type. | |
typedef TItem * | pointer |
typedef TItem & | reference |
typedef size_t | size_type |
typedef TItem | value_type |
Public Methods | |
TAllocSmartPointer (void) | |
Builds a new instance. | |
TAllocSmartPointer (const TAllocSmartPointer &rkqtITEM) | |
template<typename TDerivedItem> | TAllocSmartPointer (const TAllocSmartPointer< TDerivedItem, TAllocator > &rkqtITEM_DERIVED) |
TAllocSmartPointer (const_pointer pktITEM) | |
~TAllocSmartPointer (void) | |
Destroys the instance. | |
TAllocSmartPointer & | operator= (const_pointer pktITEM) |
void | release (void) |
template<typename TPointer> TPointer | constCast (void) const throw () |
pointer | get (void) const throw () |
bool | operator== (const TAllocSmartPointer &rkqtITEM) const throw () |
bool | operator!= (const TAllocSmartPointer &rkqtITEM) const throw () |
bool | operator! (void) const throw () |
pointer | operator-> (void) const throw (TConstraintException) |
reference | operator * (void) const throw (TConstraintException) |
Protected Methods | |
void | freeCell (void) |
void | reserveCell (const_pointer pktITEM) |
Definition at line 47 of file alloc_smart_pointer.hh.
|
Item const pointer type.
Definition at line 61 of file alloc_smart_pointer.hh. |
|
Item const reference type.
Definition at line 69 of file alloc_smart_pointer.hh. |
|
Item pointer type.
Definition at line 82 of file alloc_smart_pointer.hh. |
|
Item reference type.
Definition at line 90 of file alloc_smart_pointer.hh. |
|
Item size type.
Definition at line 98 of file alloc_smart_pointer.hh. |
|
Item value type.
Definition at line 106 of file alloc_smart_pointer.hh. |
|
Builds a new instance from another instance.
Definition at line 158 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::cell_type. |
|
Builds a new instance from another TAllocSmartPointer instantiation.
Definition at line 172 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::cell_type. |
|
Builds a new instance from a pointer.
Definition at line 200 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::cell_type, and mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::reserveCell(). |
|
Function to cast this instance to another non-const.
Definition at line 280 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::ptSharedCell. |
|
Frees space of the cell.
Definition at line 120 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::ptSharedCell. Referenced by mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::release(). |
|
Returns a pointer to the shared item.
Definition at line 318 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::ptSharedCell. |
|
Returns the shared item.
Definition at line 376 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::ptSharedCell. |
|
Returns true if this represents a NULL pointer.
Definition at line 353 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::ptSharedCell. |
|
Returns false if both instances are bound.
Definition at line 344 of file alloc_smart_pointer.hh. References mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::operator==(). |
|
Returns the shared item.
Definition at line 362 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::ptSharedCell. |
|
Creates a new cell holding the pointer pktITEM.
Definition at line 219 of file alloc_smart_pointer.hh. References mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::release(), and mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::reserveCell(). |
|
Returns true if both instances hold the same item or are both null.
Definition at line 334 of file alloc_smart_pointer.hh. Referenced by mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::operator!=(). |
|
Decrements reference count and releases the shared cell and the bound item if this is the last owner. Definition at line 240 of file alloc_smart_pointer.hh. References mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::freeCell(), and mpcl::memory::TBaseSmartPointer::ptSharedCell. Referenced by mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::operator=(), and mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::~TAllocSmartPointer(). |
|
Reserves space for a new cell that will contains pktITEM.
Definition at line 132 of file alloc_smart_pointer.hh. References mpcl::memory::TBaseSmartPointer::ptSharedCell. Referenced by mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::operator=(), and mpcl::memory::TAllocSmartPointer< TItem, TAllocator >::TAllocSmartPointer(). |