ADTF  3.18.2
d_ptr_impl< _PARENT, _PRIVATE_D >

Template to implement the Private class of the global d_pointer definitions. More...

Public Member Functions

 d_ptr_impl ()=default
 Default constructor.
 
virtual ~d_ptr_impl ()
 destructor
 
 d_ptr_impl (const d_ptr_impl &)=delete
 copying forbidden
 
d_ptr_imploperator= (const d_ptr_impl &)=delete
 
 d_ptr_impl (d_ptr_impl &&)=delete
 moving forbidden
 
d_ptr_imploperator= (d_ptr_impl &&)=delete
 
tVoid Set_p (_PARENT *_pInst)
 Sets the parent Reference. More...
 
_PRIVATE_D * operator-> () const
 Overwrites the pointer operator to return the Private class reference.
 
_PRIVATE_D * Get_d () const
 Gets the Private class reference. More...
 
 operator _PRIVATE_D * () const
 Cast operator to get the private class reference.
 
 operator d_ptr_impl< _PARENT, _PRIVATE_D > * () const
 Cast operator to get the own pointer.
 

Protected Member Functions

virtual tVoid Create_d ()
 Virtual function call to overwrite it something needs to be done on creation time.
 
virtual tVoid Release_d ()
 Virtual function call to overwrite it something needs to be done before destroying the object.
 

Protected Attributes

_PARENT * _p = nullptr
 the reference to the parent class
 

Detailed Description

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

Template to implement the Private class of the global d_pointer definitions.

Template Parameters
_PARENT[in] Parent Class name.
_PRIVATE_D[in] Private Class name.
See also
page_d_pointer

Definition at line 21 of file d_ptr.h.

Member Function Documentation

◆ Get_d()

_PRIVATE_D* Get_d ( ) const
inline

Gets the Private class reference.

Returns
Returns the Private class reference.

Definition at line 70 of file d_ptr.h.

◆ Set_p()

tVoid Set_p ( _PARENT *  _pInst)
inline

Sets the parent Reference.

This must be called within the constructor of Parent Class. Use the helper macro A_UTILS_D_CREATE.

Parameters
[in]_pInsta parent reference.
Returns
void

Definition at line 52 of file d_ptr.h.

References d_ptr_impl< _PARENT, _PRIVATE_D >::_p, and d_ptr_impl< _PARENT, _PRIVATE_D >::Create_d().

Referenced by d_ptr< _PARENT, _PRIVATE_D >::Set_p().