ADTF
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
ISampleReaderabstract

Interface for sample reads that read from sample streams via input pins. More...

#include <samplestreamer_intf.h>

Inheritance diagram for ISampleReader:
[legend]

Public Member Functions

virtual tResult GetNextSample (ucom::ant::iobject_ptr< const ant::ISample > &pSample)=0
 Reads the next available sample from the associated sample stream.
 
virtual tResult GetLastSample (ucom::ant::iobject_ptr< const ant::ISample > &pSample)=0
 Reads the latest available sample from the associated sample stream.
 
virtual tResult GetLastType (ucom::ant::iobject_ptr< const IStreamType > &pType)=0
 Returns the last stream type that was read from the sample stream.
 
virtual tResult SetStreamError (tResult oError)=0
 Sets an error on the associated sample stream.
 
virtual tResult ReadAllAvailableItems ()=0
 Reads all available items from the sample stream into internal queues.
 
- Public Member Functions inherited from ISampleStreamer
virtual void SetName (const char *strName)=0
 Sets the name of the streamer.
 
virtual tResult GetName (base::ant::IString &&strName)=0
 Retrieves the name of the streamer.
 
virtual tResult SetType (const ucom::ant::iobject_ptr< const ant::IStreamType > &pStreamType)=0
 Sets the initial stream type of a streamer.
 
virtual tResult GetType (ucom::ant::iobject_ptr< const ant::IStreamType > &pStreamType) const =0
 Returns the initial stream type of the streamer.
 
virtual tResult BeginStreaming (ant::ISampleStream &pStream)=0
 Begin streaming on the given sample stream.
 
virtual tResult EndStreaming ()=0
 End streaming.
 
virtual tResult SetStreamerPin (const ucom::ant::iobject_ptr< flash::IStreamerPin > &pStreamerPin)=0
 Sets the pin that the streamer is associated with.
 

Detailed Description

Interface for sample reads that read from sample streams via input pins.

Definition at line 187 of file samplestreamer_intf.h.

Member Function Documentation

◆ GetLastSample()

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

Reads the latest available sample from the associated sample stream.

If more than a single new sample was availablle, all but the last sample will be discarded.

If no new sample was available the last sample previously fetched will be returned again.

Parameters
[out]pSampleThis will refrerence the sample.
Return values
ERR_EMTPYNo sample available

Implemented in cNullReader, cSampleReader, cSampleReader, and cNullReader.

◆ GetLastType()

virtual tResult GetLastType ( ucom::ant::iobject_ptr< const IStreamType > & pType)
pure virtual

Returns the last stream type that was read from the sample stream.

Parameters
[out]pTypeThis will reference the last stream type
Returns

Implemented in cNullReader, cSampleReader, cSampleReader, and cNullReader.

◆ GetNextSample()

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

Reads the next available sample from the associated sample stream.

Parameters
[out]pSampleThis will refrerence the sample.
Return values
ERR_EMTPYNo sample available

Implemented in cNullReader, cSampleReader, cSampleReader, and cNullReader.

◆ ReadAllAvailableItems()

virtual tResult ReadAllAvailableItems ( )
pure virtual

Reads all available items from the sample stream into internal queues.

Returns
Standard result.

Implemented in cNullReader, cSampleReader, cSampleReader, and cNullReader.

◆ SetStreamError()

virtual tResult SetStreamError ( tResult oError)
pure virtual

Sets an error on the associated sample stream.

Parameters
[in]oErrorThe error.
Returns
Standard result.

Implemented in cNullReader, cSampleReader, cSampleReader, and cNullReader.