ADTF  3.18.2
d_ptr< _PARENT, _PRIVATE_D >

Template class for the d-pointer Reference class withing the Parent Class. More...

Public Types

typedef d_ptr< _PARENT, _PRIVATE_D > self_type
 self type
 

Public Member Functions

 d_ptr ()=default
 Default constructor.
 
virtual ~d_ptr ()
 Destructor.
 
 d_ptr (const d_ptr &)=delete
 
d_ptroperator= (const d_ptr &)=delete
 
 d_ptr (d_ptr &&o_oOther)
 
d_ptroperator= (d_ptr &&o_oOther)
 
tVoid Set_p (_PARENT *_pInst)
 Sets the internal pointer. More...
 
_PRIVATE_D * operator-> () const
 Pointer operator enable access to the internal pointer.
 
_PRIVATE_D * Get_d () const
 Gets the internal pointer. More...
 
 operator _PRIVATE_D * () const
 Cast operator enable access to the internal pointer.
 
self_typeoperator= (_PRIVATE_D *_dInst)
 Assignment operator allows to set the internal pointer value.
 
tVoid Swap (self_type &o_oOther)
 Swap *this d_ptr with another one. More...
 

Protected Attributes

internal_type_dRef = nullptr
 The internal pointer to the private class.
 

Private Types

typedef d_ptr_impl< _PARENT, _PRIVATE_D > internal_type
 internally held type
 

Detailed Description

template<class _PARENT, class _PRIVATE_D>
class A_UTILS_NS::d_ptr< _PARENT, _PRIVATE_D >

Template class for the d-pointer Reference class withing the Parent Class.

This is declared with the helper macro A_UTILS_D.

Parameters
_PARENTThe parent Class Name.
_PRIVATE_DThe Private Class Name.

Definition at line 116 of file d_ptr.h.

Member Function Documentation

◆ Get_d()

_PRIVATE_D* Get_d ( ) const
inline

Gets the internal pointer.

Returns
Internal pointer value

Definition at line 187 of file d_ptr.h.

References d_ptr< _PARENT, _PRIVATE_D >::_dRef.

Referenced by d_ptr< _PARENT, _PRIVATE_D >::operator _PRIVATE_D *(), and d_ptr< _PARENT, _PRIVATE_D >::operator->().

◆ Set_p()

tVoid Set_p ( _PARENT *  _pInst)
inline

Sets the internal pointer.

Parameters
_pInst[in] New pointer value
Returns
void

Definition at line 167 of file d_ptr.h.

References d_ptr< _PARENT, _PRIVATE_D >::_dRef, and d_ptr_impl< _PARENT, _PRIVATE_D >::Set_p().

◆ Swap()

tVoid Swap ( self_type o_oOther)
inline

Swap *this d_ptr with another one.

Parameters
[in,out]o_oOtherTo swap *this with.

Definition at line 217 of file d_ptr.h.

References d_ptr< _PARENT, _PRIVATE_D >::_dRef.

Referenced by std::swap().