OpenClonk
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros
StdBasicPtrAdapt< T > Struct Template Reference

#include <StdAdaptors.h>

Inheritance diagram for StdBasicPtrAdapt< T >:
[legend]

Public Member Functions

 StdBasicPtrAdapt (T *&rpObj, bool fAllowNull=true, const char *szNaming="Data")
 
bool operator== (const T &nValue) const
 
StdBasicPtrAdaptoperator= (const T &nValue)
 
bool operator== (const T *pValue) const
 
StdBasicPtrAdaptoperator= (const T *pValue)
 

Public Attributes

T *& rpObj
 
bool fAllowNull
 
const char * szNaming
 

Detailed Description

template<class T>
struct StdBasicPtrAdapt< T >

Definition at line 492 of file StdAdaptors.h.

Constructor & Destructor Documentation

template<class T >
StdBasicPtrAdapt< T >::StdBasicPtrAdapt ( T *&  rpObj,
bool  fAllowNull = true,
const char *  szNaming = "Data" 
)
inline

Definition at line 494 of file StdAdaptors.h.

Member Function Documentation

template<class T >
StdBasicPtrAdapt& StdBasicPtrAdapt< T >::operator= ( const T &  nValue)
inline

Definition at line 500 of file StdAdaptors.h.

References StdBasicPtrAdapt< T >::rpObj.

500 { delete rpObj; rpObj = new T(nValue); return *this; }
template<class T >
StdBasicPtrAdapt& StdBasicPtrAdapt< T >::operator= ( const T *  pValue)
inline

Definition at line 502 of file StdAdaptors.h.

References StdBasicPtrAdapt< T >::rpObj.

502 { delete rpObj; rpObj = pValue; return *this; }
template<class T >
bool StdBasicPtrAdapt< T >::operator== ( const T &  nValue) const
inline

Definition at line 499 of file StdAdaptors.h.

499 { return rpObj && *rpObj == nValue; }
template<class T >
bool StdBasicPtrAdapt< T >::operator== ( const T *  pValue) const
inline

Definition at line 501 of file StdAdaptors.h.

501 { return rpObj == pValue; }

Member Data Documentation

template<class T >
bool StdBasicPtrAdapt< T >::fAllowNull

Definition at line 496 of file StdAdaptors.h.

template<class T >
T*& StdBasicPtrAdapt< T >::rpObj
template<class T >
const char* StdBasicPtrAdapt< T >::szNaming

Definition at line 496 of file StdAdaptors.h.


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