# Smart pointers

Collaboration diagram for Smart pointers:

## Classes

struct | std::less< Loki::StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > >
class | Loki::RefToValue< T >
struct | Loki::NullPointerException
class | Loki::SmartPtr< T, OwnershipPolicy, ConversionPolicy, CheckingPolicy, StoragePolicy, ConstnessPolicy >
class | Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >

## Namespaces

namespace | std

## Modules

| Ownership policies
| Storage policies
| Conversion policies
| Checking policies
| StrongPtr Ownership policies
| Delete policies
| Reset policies

## Functions

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP1, typename U >
bool | Loki::operator== (const SmartPtr< T, OP, CP, KP, SP, CNP1 > &lhs, U *rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP1, typename U >
bool | Loki::operator== (U *lhs, const SmartPtr< T, OP, CP, KP, SP, CNP1 > &rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator!= (const SmartPtr< T, OP, CP, KP, SP, CNP > &lhs, U *rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator!= (U *lhs, const SmartPtr< T, OP, CP, KP, SP, CNP > &rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator< (const SmartPtr< T, OP, CP, KP, SP, CNP > &lhs, U *rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator< (U *lhs, const SmartPtr< T, OP, CP, KP, SP, CNP > &rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator> (const SmartPtr< T, OP, CP, KP, SP, CNP > &lhs, U *rhs)
| /////////////////////////////////////////////////////////////////////////////
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator> (U *lhs, const SmartPtr< T, OP, CP, KP, SP, CNP > &rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator<= (const SmartPtr< T, OP, CP, KP, SP, CNP > &lhs, U *rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator<= (U *lhs, const SmartPtr< T, OP, CP, KP, SP, CNP > &rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator>= (const SmartPtr< T, OP, CP, KP, SP, CNP > &lhs, U *rhs)
template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >
bool | Loki::operator>= (U *lhs, const SmartPtr< T, OP, CP, KP, SP, CNP > &rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator== (const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &lhs, U *rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator== (U *lhs, const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator!= (const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &lhs, U *rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator!= (U *lhs, const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator< (const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &lhs, U *rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator< (U *lhs, const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator> (U *lhs, const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator<= (const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &lhs, U *rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator<= (U *lhs, const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator>= (const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &lhs, U *rhs)
template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>
bool | Loki::operator>= (U *lhs, const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > &rhs)

## Detailed Description

Policy based implementation of a smart pointer

## Function Documentation

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator!= | ( | U * | lhs,
|  | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator!= for lhs = raw pointer, rhs = StrongPtr

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::Equals().

Here is the call graph for this function:

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator!= | ( | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator!= for lhs = StrongPtr, rhs = raw pointer

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::Equals().

Here is the call graph for this function:

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >

bool Loki::operator!= | ( | U * | lhs,
|  | const SmartPtr< T, OP, CP, KP, SP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator!= for lhs = raw pointer, rhs = SmartPtr

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >

bool Loki::operator!= | ( | const SmartPtr< T, OP, CP, KP, SP, CNP > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator!= for lhs = SmartPtr, rhs = raw pointer

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator< | ( | U * | lhs,
|  | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator< for lhs = raw pointer, rhs = StrongPtr

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::GreaterThan().

Here is the call graph for this function:

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator< | ( | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator< for lhs = StrongPtr, rhs = raw pointer

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::LessThan().

Here is the call graph for this function:

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >

bool Loki::operator< | ( | U * | lhs,
|  | const SmartPtr< T, OP, CP, KP, SP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator< for lhs = raw pointer, rhs = SmartPtr

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >

bool Loki::operator< | ( | const SmartPtr< T, OP, CP, KP, SP, CNP > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator< for lhs = SmartPtr, rhs = raw pointer

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator<= | ( | U * | lhs,
|  | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator<= for lhs = raw pointer, rhs = StrongPtr

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::LessThan().

Here is the call graph for this function:

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator<= | ( | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator<= for lhs = StrongPtr, rhs = raw pointer

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::GreaterThan().

Here is the call graph for this function:

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >

bool Loki::operator<= | ( | U * | lhs,
|  | const SmartPtr< T, OP, CP, KP, SP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator<= for lhs = raw pointer, rhs = SmartPtr

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >

bool Loki::operator<= | ( | const SmartPtr< T, OP, CP, KP, SP, CNP > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator<= for lhs = SmartPtr, rhs = raw pointer

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator== | ( | U * | lhs,
|  | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator== for lhs = raw pointer, rhs = StrongPtr

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::Equals().

Here is the call graph for this function:

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator== | ( | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator== for lhs = StrongPtr, rhs = raw pointer

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::Equals().

Here is the call graph for this function:

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP1, typename U >

bool Loki::operator== | ( | U * | lhs,
|  | const SmartPtr< T, OP, CP, KP, SP, CNP1 > & | rhs |
| ) |  |  | `[inline]`

operator== for lhs = raw pointer, rhs = SmartPtr

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP1, typename U >

bool Loki::operator== | ( | const SmartPtr< T, OP, CP, KP, SP, CNP1 > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator== for lhs = SmartPtr, rhs = raw pointer

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator> | ( | U * | lhs,
|  | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator> for lhs = raw pointer, rhs = StrongPtr

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::LessThan().

Here is the call graph for this function:

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >

bool Loki::operator> | ( | U * | lhs,
|  | const SmartPtr< T, OP, CP, KP, SP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator> for lhs = raw pointer, rhs = SmartPtr

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator>= | ( | U * | lhs,
|  | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator>= for lhs = raw pointer, rhs = StrongPtr

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::GreaterThan().

Here is the call graph for this function:

template<typename U , typename T , bool S, class OP , class CP , template< class > class KP, template< class > class RP, template< class > class DP, template< class > class CNP>

bool Loki::operator>= | ( | const StrongPtr< T, S, OP, CP, KP, RP, DP, CNP > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator>= for lhs = StrongPtr, rhs = raw pointer

References Loki::StrongPtr< T, Strong, OwnershipPolicy, ConversionPolicy, CheckingPolicy, ResetPolicy, DeletePolicy, ConstnessPolicy >::LessThan().

Here is the call graph for this function:

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >

bool Loki::operator>= | ( | U * | lhs,
|  | const SmartPtr< T, OP, CP, KP, SP, CNP > & | rhs |
| ) |  |  | `[inline]`

operator>= for lhs = raw pointer, rhs = SmartPtr

template<typename T , template< class > class OP, class CP , template< class > class KP, template< class > class SP, template< class > class CNP, typename U >

bool Loki::operator>= | ( | const SmartPtr< T, OP, CP, KP, SP, CNP > & | lhs,
|  | U * | rhs |
| ) |  |  | `[inline]`

operator>= for lhs = SmartPtr, rhs = raw pointer