ETL  0.04.19
Public Types | Public Member Functions | Protected Attributes | List of all members
loose_handle< T > Class Template Reference

Loose Object Handle. More...

#include <ETL/handle>

Public Types

typedef T value_type
typedef T & reference
typedef const T & const_reference
typedef T * pointer
typedef const T * const_pointer
typedef int count_type
typedef int size_type

Public Member Functions

 loose_handle ()
 Default constructor - empty handle.
 loose_handle (pointer x)
 Constructor that constructs from a pointer to new object.
 loose_handle (const loose_handle< value_type > &x)
 Default copy constructor.
 loose_handle (const handle< value_type > &x)
template<class U >
const loose_handle< value_type > & operator= (const handle< U > &x)
template<class U >
const loose_handle< value_type > & operator= (const loose_handle< U > &x)
const loose_handle< value_type > & operator= (const loose_handle< value_type > &x)
 Assignment operator.
loose_handle< value_type > & swap (loose_handle< value_type > &x)
 Swaps the values of two handles without reference counts.
void detach ()
 Handle release procedure.
void reset ()
bool empty () const
loose_handle< const value_typeconstant () const
 Returns a constant handle to our object.
count_type count () const
 Returns number of instances.
reference operator* () const
pointer operator-> () const
 operator loose_handle< const value_type > () const
 static_cast<> overload
 operator handle< value_type > () const
 operator rhandle< value_type > () const
pointer get () const
 Returns pointer to the object that is being wrapped.
 operator bool () const
 More explicit bool cast.
bool operator! () const
void ref ()
bool unref ()

Protected Attributes

value_typeobj
 Pointer to object.

Detailed Description

template<class T>
class loose_handle< T >

Loose Object Handle.

See Also
shared_object, handle
Todo:
This needs to be documented

Definition at line 661 of file _handle.h.

Member Typedef Documentation

template<class T>
typedef T loose_handle< T >::value_type

Definition at line 665 of file _handle.h.

template<class T>
typedef T& loose_handle< T >::reference

Definition at line 666 of file _handle.h.

template<class T>
typedef const T& loose_handle< T >::const_reference

Definition at line 667 of file _handle.h.

template<class T>
typedef T* loose_handle< T >::pointer

Definition at line 668 of file _handle.h.

template<class T>
typedef const T* loose_handle< T >::const_pointer

Definition at line 669 of file _handle.h.

template<class T>
typedef int loose_handle< T >::count_type

Definition at line 670 of file _handle.h.

template<class T>
typedef int loose_handle< T >::size_type

Definition at line 671 of file _handle.h.

Constructor & Destructor Documentation

template<class T>
loose_handle< T >::loose_handle ( )
inline

Default constructor - empty handle.

Definition at line 682 of file _handle.h.

template<class T>
loose_handle< T >::loose_handle ( pointer  x)
inline

Constructor that constructs from a pointer to new object.

Definition at line 685 of file _handle.h.

template<class T>
loose_handle< T >::loose_handle ( const loose_handle< value_type > &  x)
inline

Default copy constructor.

Definition at line 688 of file _handle.h.

template<class T>
loose_handle< T >::loose_handle ( const handle< value_type > &  x)
inline

Definition at line 690 of file _handle.h.

Member Function Documentation

template<class T>
template<class U >
const loose_handle<value_type>& loose_handle< T >::operator= ( const handle< U > &  x)
inline

Definition at line 693 of file _handle.h.

References handle< T >::get(), and loose_handle< T >::obj.

template<class T>
template<class U >
const loose_handle<value_type>& loose_handle< T >::operator= ( const loose_handle< U > &  x)
inline

Definition at line 703 of file _handle.h.

References loose_handle< T >::get(), and loose_handle< T >::obj.

template<class T>
const loose_handle<value_type>& loose_handle< T >::operator= ( const loose_handle< value_type > &  x)
inline

Assignment operator.

Definition at line 714 of file _handle.h.

References loose_handle< T >::get(), and loose_handle< T >::obj.

template<class T>
loose_handle<value_type>& loose_handle< T >::swap ( loose_handle< value_type > &  x)
inline

Swaps the values of two handles without reference counts.

Definition at line 725 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
void loose_handle< T >::detach ( )
inline

Handle release procedure.

Definition at line 734 of file _handle.h.

References loose_handle< T >::obj.

Referenced by loose_handle< T >::reset().

template<class T>
void loose_handle< T >::reset ( )
inline

Definition at line 739 of file _handle.h.

References loose_handle< T >::detach().

template<class T>
bool loose_handle< T >::empty ( ) const
inline

Definition at line 741 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
loose_handle<const value_type> loose_handle< T >::constant ( ) const
inline

Returns a constant handle to our object.

Definition at line 744 of file _handle.h.

template<class T>
count_type loose_handle< T >::count ( ) const
inline

Returns number of instances.

Definition at line 748 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
reference loose_handle< T >::operator* ( ) const
inline

Definition at line 752 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
pointer loose_handle< T >::operator-> ( ) const
inline

Definition at line 756 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
loose_handle< T >::operator loose_handle< const value_type > ( ) const
inline

static_cast<> overload

static_cast<> overload (for consts)

Definition at line 765 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
loose_handle< T >::operator handle< value_type > ( ) const
inline

Definition at line 768 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
loose_handle< T >::operator rhandle< value_type > ( ) const
inline

Definition at line 771 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
pointer loose_handle< T >::get ( ) const
inline
template<class T>
loose_handle< T >::operator bool ( ) const
inline

More explicit bool cast.

Definition at line 778 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
bool loose_handle< T >::operator! ( ) const
inline

Definition at line 782 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
void loose_handle< T >::ref ( )
inline

Definition at line 785 of file _handle.h.

References loose_handle< T >::obj.

template<class T>
bool loose_handle< T >::unref ( )
inline

Definition at line 787 of file _handle.h.

References loose_handle< T >::obj.

Member Data Documentation

template<class T>
value_type* loose_handle< T >::obj
protected

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