proxy_ptr Class Template Reference
[Smart Pointers library]

#include <stlsoft/smartptr/proxy_ptr.hpp>

List of all members.


Detailed Description

template<typename T>
class stlsoft::proxy_ptr< T >

This class emulates a pointer in all respects, and is useful as a generic code testing tool, and is simply an aid to self-documentation.

Parameters:
T The value type

Public Types

typedef T value_type
 The value type.
typedef proxy_ptr< T > class_type
 The current parameterisation of the type.
typedef value_typeresource_type
typedef value_type const * const_resource_type

Public Member Functions

 proxy_ptr (value_type *t)
 Construct from a pointer to "borrow".
proxy_ptroperator= (value_type *t)
 Assignment from a new pointer.
 operator value_type * ()
 Implicit conversion to pointer to the underlying pointer.
 operator value_type const * () const
 Implicit conversion to pointer-to-const to the underlying pointer.
value_typeoperator* ()
 Indirection operator.
value_type const & operator* () const
 Indirection operator.
value_typeoperator-> ()
 Member-selection operator.
value_type const * operator-> () const
 Member-selection operator.
value_typeget_ptr () const
 Returns the underlying pointer value.
value_typeget () const
 Returns the underlying pointer value.
value_typeGetPointer () const
 Returns the underlying pointer value.
void clear ()
 Sets the underlying pointer value to null.

Member Typedef Documentation

typedef T value_type

The value type.

typedef proxy_ptr<T> class_type

The current parameterisation of the type.


Constructor & Destructor Documentation

proxy_ptr ( value_type t  )  [inline, explicit]

Construct from a pointer to "borrow".


Member Function Documentation

proxy_ptr& operator= ( value_type t  )  [inline]

Assignment from a new pointer.

operator value_type * (  )  [inline]

Implicit conversion to pointer to the underlying pointer.

operator value_type const * (  )  const [inline]

Implicit conversion to pointer-to-const to the underlying pointer.

value_type& operator* (  )  [inline]

Indirection operator.

Note:
This method does a debug-time assertion that the underlying pointer is non-null

References STLSOFT_MESSAGE_ASSERT.

value_type const& operator* (  )  const [inline]

Indirection operator.

Note:
This method does a debug-time assertion that the underlying pointer is non-null

References STLSOFT_MESSAGE_ASSERT.

value_type* operator-> (  )  [inline]

Member-selection operator.

Note:
This method does a debug-time assertion that the underlying pointer is non-null

References STLSOFT_MESSAGE_ASSERT.

value_type const* operator-> (  )  const [inline]

Member-selection operator.

Note:
This method does a debug-time assertion that the underlying pointer is non-null

References STLSOFT_MESSAGE_ASSERT.

value_type* get_ptr (  )  const [inline]

Returns the underlying pointer value.

Deprecated:
This function will be removed in a future release. Users should instead invoke get()

value_type* get (  )  const [inline]

Returns the underlying pointer value.

Referenced by stlsoft::get_ptr().

value_type* GetPointer (  )  const [inline]

Returns the underlying pointer value.

Deprecated:
This method will be removed in a future version

void clear (  )  [inline]

Sets the underlying pointer value to null.


The documentation for this class was generated from the following file:

Generated on Thu Jun 10 08:58:56 2010 for STLSoft by  doxygen 1.5.6