SYNOPSIS

#include <pointer.h>

Public Member Functions

Pointer (T *ptr=NULL)

Pointer (const Pointer< T > &ref)

virtual ~Pointer ()

Pointer & operator= (const Pointer< T > &ref)

T & operator* () const

T * getObject () const

T * operator-> () const

bool operator! () const

int operator++ () const

int operator-- () const

Protected Member Functions

void ptrDetach (void)

Protected Attributes

unsigned * ptrCount

T * ptrObject

Detailed Description

template<class T>class ost::Pointer< T >

Used to create and manage referece counted pointers.

Author:

David Sugar [email protected] reference counted pointer template.

Constructor & Destructor Documentation

template<class T> \fBost::Pointer\fP< T >::\fBPointer\fP (T *ptr = \fCNULL\fP)\fC [inline]\fP, \fC [explicit]\fP

References ost::Pointer< T >::ptrCount.

template<class T> \fBost::Pointer\fP< T >::\fBPointer\fP (const \fBPointer\fP< T > &ref)\fC [inline]\fP

References ost::Pointer< T >::ptrCount, and ost::Pointer< T >::ptrObject.

template<class T> virtual \fBost::Pointer\fP< T >::~\fBPointer\fP ()\fC [inline]\fP, \fC [virtual]\fP

References ost::Pointer< T >::ptrDetach().

Member Function Documentation

template<class T> T* \fBost::Pointer\fP< T >::getObject (void) const\fC [inline]\fP

References ost::Pointer< T >::ptrObject.

template<class T> bool \fBost::Pointer\fP< T >::operator! (void) const\fC [inline]\fP

References ost::Pointer< T >::ptrCount.

template<class T> T& \fBost::Pointer\fP< T >::operator* () const\fC [inline]\fP

References ost::Pointer< T >::ptrObject.

template<class T> int \fBost::Pointer\fP< T >::operator++ () const\fC [inline]\fP

template<class T> int \fBost::Pointer\fP< T >::operator-- () const\fC [inline]\fP

References ost::Pointer< T >::ptrCount.

template<class T> T* \fBost::Pointer\fP< T >::operator-> () const\fC [inline]\fP

References ost::Pointer< T >::ptrObject.

template<class T> \fBPointer\fP& \fBost::Pointer\fP< T >::operator= (const \fBPointer\fP< T > &ref)\fC [inline]\fP

References ost::Pointer< T >::ptrCount, ost::Pointer< T >::ptrDetach(), and ost::Pointer< T >::ptrObject.

template<class T> void \fBost::Pointer\fP< T >::ptrDetach (void)\fC [inline]\fP, \fC [protected]\fP

References ost::Pointer< T >::ptrCount, and ost::Pointer< T >::ptrObject.

Referenced by ost::Pointer< T >::operator=(), and ost::Pointer< T >::~Pointer().

Member Data Documentation

template<class T> unsigned* \fBost::Pointer\fP< T >::ptrCount\fC [protected]\fP

Referenced by ost::Pointer< T >::operator!(), ost::Pointer< T >::operator--(), ost::Pointer< T >::operator=(), ost::Pointer< T >::Pointer(), and ost::Pointer< T >::ptrDetach().

template<class T> T* \fBost::Pointer\fP< T >::ptrObject\fC [protected]\fP

Referenced by ost::Pointer< T >::getObject(), ost::Pointer< T >::operator*(), ost::Pointer< T >::operator->(), ost::Pointer< T >::operator=(), ost::Pointer< T >::Pointer(), and ost::Pointer< T >::ptrDetach().

Author

Generated automatically by Doxygen for GNU CommonC++ from the source code.