ADTF  3.14.3
iobject_ptr_base< T >abstract

Base class for iobject_ptr<T> defining their commonly used interface methods. More...

Inheritance diagram for iobject_ptr_base< T >:
[legend]

Public Types

typedef T element_type
 Contained type to manage an object of.
 

Public Member Functions

virtual T * Get () const =0
 Get raw pointer to shared object. More...
 
virtual tResult Reset (const iobject_ptr< T > &i_oOther)=0
 Reset this object_ptr<> with the content of another iobject_ptr<> More...
 
virtual T * operator-> () const =0
 Operator-> overload to treat object_ptr<> types like real pointers. More...
 

Protected Member Functions

 ~iobject_ptr_base ()=default
 Destructor.
 

Private Member Functions

virtual detail::iobject_ptr_ref< size_t > * GetObjPtrRef () const =0
 Get the reference counter. More...
 

Detailed Description

template<typename T>
class adtf::ucom::ant::iobject_ptr_base< T >

Base class for iobject_ptr<T> defining their commonly used interface methods.

Template Parameters
TType of the managed resource. Must be derived from IObject

Definition at line 22 of file object_ptr_intf.h.

Member Function Documentation

◆ Get()

◆ GetObjPtrRef()

virtual detail::iobject_ptr_ref<size_t>* GetObjPtrRef ( ) const
privatepure virtual

Get the reference counter.

Returns
Pointer to the reference counter.

Referenced by weak_object_ptr< T >::operator=().

◆ operator->()

virtual T* operator-> ( ) const
pure virtual

Operator-> overload to treat object_ptr<> types like real pointers.

Returns
Pointer to shared object

◆ Reset()

virtual tResult Reset ( const iobject_ptr< T > &  i_oOther)
pure virtual

Reset this object_ptr<> with the content of another iobject_ptr<>

Parameters
[in]i_oOtherContains the shared object to reset this type with
Postcondition
Reference counter increased by one. If another object is already managed, the reference count for this object gets decreased by one.
Returns
Standard error code.
Return values
ERR_NOERROREverything went fine
ERR_NO_INTERFACEManaged resource owned by i_oOther does not expose interface type T. *this is reset to nullptr

Referenced by adtf::streaming::devil::add_binding_proxy(), adtf::streaming::devil::add_data_in_port(), adtf::streaming::devil::add_data_out_port(), adtf::streaming::devil::add_graph_object(), adtf::streaming::devil::add_sample_stream_in_port(), adtf::streaming::devil::add_sample_stream_out_port(), adtf::streaming::ant::create_pin(), cLastSampleReader::GetLastSample(), cSampleReader::GetLastType(), cStreamItem::GetObject(), configuration< Interface >::GetProperties(), cStreamItem::GetSample(), cSampleReader::GetSampleInStream(), cStreamItem::GetStreamType(), adtf::streaming::ant::operator>>(), and adtf::ucom::ant::reset_object_ptr().


Copyright © Audi Electronics Venture GmbH. All rights reserved. (Generated on Thu Jun 9 2022 by doxygen 1.9.1)