Webmaster  |  Imprint 
C++ Server Pages
Main  |  License  |  Documentation  |  Download 

Pool::PoolObject Class Reference

#include <cxxtools/pool.h>

List of all members.

Public Types

typedef Pool< T, CreatorType > pool_type
typedef PoolObjectptr_type
typedef const PoolObjectconst_ptr_type

Public Member Functions

 PoolObject (T *o, pool_type &p)
 PoolObject (const PoolObject &s)
PoolObjectoperator= (const PoolObject &s)
void release (bool reuse=true)
T * operator-> () const
 The object can be dereferenced like the held object.
T & operator* () const
 The object can be dereferenced like the held object.
 operator T * () const
 The object is convertable to a pointer to the held object.
 operator T & () const
 The object is convertable to a reference to the held object.
bool operator== (const T *p) const


Detailed Description

template<typename T, typename CreatorType = DefaultCreator<T>>
class cxxtools::Pool< T, CreatorType >::PoolObject

The PoolObject holds a reference to the object. The held object is released for reuse, when the last reference is destroyed.

Member Function Documentation

void release ( bool  reuse = true  ) 

The reference can be dropped before destruction.

Copyright © 2008 The Tntnet Development Team
Tntnet 1.6