ADTF  3.18.2
IStreamItemabstract

The IStreamItem interface is the base type for all object which are passed through a stream. More...

Inheritance diagram for IStreamItem:
[legend]

Public Types

enum class  tType : uint32_t { Undefined = 0 , StreamType = 1 , Sample = 2 }
 serval types are defined More...
 

Public Member Functions

virtual tType GetType () const =0
 Retrieves the type of the sample item. More...
 
virtual tResult GetObject (ucom::ant::iobject_ptr< const ucom::ant::IObject > &pObject) const =0
 Retrieves the object of the StreamItem. More...
 
virtual tResult GetSample (ucom::ant::iobject_ptr< const ISample > &pSample) const =0
 Retrieves the sample of the StreamItem if GetType is tType::Sample. More...
 
virtual tResult GetStreamType (ucom::ant::iobject_ptr< const IStreamType > &pStreamType) const =0
 Retrieves the StreamType of the StreamItem if GetType is tType::StreamType. More...
 
virtual tResult SetSample (const ucom::ant::iobject_ptr< const ISample > &pSample)=0
 Sets a Sample to the StreamItem container and set tType::Sample. More...
 
virtual tResult SetStreamType (const ucom::ant::iobject_ptr< const IStreamType > &pStreamType)=0
 Sets a StreamType to the StreamItem container and set tType::StreamType. More...
 

Protected Member Functions

 ~IStreamItem ()=default
 not destructable
 

Detailed Description

The IStreamItem interface is the base type for all object which are passed through a stream.

Definition at line 22 of file streamitem_intf.h.

Member Enumeration Documentation

◆ tType

enum tType : uint32_t
strong

serval types are defined

Enumerator
StreamType 

item is a IStreamType. Mind: All StreamType changes will be queue too !!

Sample 

item is a queue item contains a ISample

Definition at line 30 of file streamitem_intf.h.

Member Function Documentation

◆ GetObject()

virtual tResult GetObject ( ucom::ant::iobject_ptr< const ucom::ant::IObject > &  pObject) const
pure virtual

Retrieves the object of the StreamItem.

Remarks
Mind, this could result in a ucom_cast call!
Return values
ERR_NOERRORObject successfully retrieved

Implemented in cStreamItem.

◆ GetSample()

virtual tResult GetSample ( ucom::ant::iobject_ptr< const ISample > &  pSample) const
pure virtual

Retrieves the sample of the StreamItem if GetType is tType::Sample.

The StreamItem was created to prevent ucom_casts call while transmissions and to define clearly which items are supported.

Return values
ERR_NOERRORSample successfully retrieved

Implemented in cStreamItem.

Referenced by cStreamItem::cStreamItem().

◆ GetStreamType()

virtual tResult GetStreamType ( ucom::ant::iobject_ptr< const IStreamType > &  pStreamType) const
pure virtual

Retrieves the StreamType of the StreamItem if GetType is tType::StreamType.

The StreamItem was created to prevent ucom_casts call while transmissions and to define clearly which items are supported.

Return values
ERR_NOERRORStreamType successfully retrieved

Implemented in cStreamItem.

Referenced by cStreamItem::cStreamItem(), and cSampleReader::ProcessStreamItem().

◆ GetType()

virtual tType GetType ( ) const
pure virtual

Retrieves the type of the sample item.

See tType for more info.

Returns
Returns the type of the sample item

Implemented in cStreamItem.

Referenced by cSampleReader::ProcessStreamItem(), and cLimitedSampleReaderQueue::Push().

◆ SetSample()

virtual tResult SetSample ( const ucom::ant::iobject_ptr< const ISample > &  pSample)
pure virtual

Sets a Sample to the StreamItem container and set tType::Sample.

The StreamItem was created to prevent ucom_casts call while transmissions and to define clearly which items are supported.

Parameters
pSample[in] Sample to set
Return values
ERR_NOERRORSample successfully set

Implemented in cStreamItem.

Referenced by cStreamItem::CopyTo().

◆ SetStreamType()

virtual tResult SetStreamType ( const ucom::ant::iobject_ptr< const IStreamType > &  pStreamType)
pure virtual

Sets a StreamType to the StreamItem container and set tType::StreamType.

The StreamItem was created to prevent ucom_casts call while transmissions and to define clearly which items are supported.

Parameters
pStreamType[in] StreamType to set
Return values
ERR_NOERRORSample successfully set

Implemented in cStreamItem.

Referenced by cStreamItem::CopyTo().