ADTF
Loading...
Searching...
No Matches
adtf::streaming::ant::streaming_level_machine Class Reference

#include <streaming_source.h>

Inherits adtf::ucom::ant::level_machine< Subclass, LevelType, START_LEVEL >.

Inherited by adtf::filter::cSampleStreamingSink [protected], adtf::filter::cSampleStreamingSource [protected], adtf::streaming::ant::cSampleStreamingSink, and adtf::streaming::ant::cSampleStreamingSource.

Protected Member Functions

 streaming_level_machine (const streaming_level_machine &)=delete
 
 streaming_level_machine (streaming_level_machine &&)=delete
 
streaming_level_machineoperator= (const streaming_level_machine &)=delete
 
streaming_level_machineoperator= (streaming_level_machine &&)=delete
 
tResult SetLevel (IStreamingService::tStreamingState eStreamingState)
 
virtual tResult Construct ()
 
virtual tResult Destruct ()
 
virtual tResult Init ()
 
virtual tResult Shutdown ()
 
virtual tResult StartStreaming ()
 
virtual tResult StopStreaming ()
 
- Protected Member Functions inherited from adtf::ucom::ant::level_machine< Subclass, LevelType, START_LEVEL >
virtual ~level_machine ()=default
 DTOR.
 
LevelType GetLevel () const
 

Additional Inherited Members

- Public Member Functions inherited from adtf::ucom::ant::level_machine< Subclass, LevelType, START_LEVEL >
template<typename ... InnerHandlers>
tResult ChangeLevel (LevelType eLevel)
 
- Protected Types inherited from adtf::ucom::ant::level_machine< Subclass, LevelType, START_LEVEL >
enum  tDirection : uint8_t { Inc = 0 , Dec = 1 }
 Direction of entering a new Level. More...
 
typedef tResult(Subclass::* tChangeMethod) ()
 Defintion of function type called within the handler implementation.
 

Detailed Description

The Streaming Service Level Machine implementation.

Member Function Documentation

◆ Construct()

virtual tResult adtf::streaming::ant::streaming_level_machine::Construct ( )
inlineprotectedvirtual

Construct transition while changing from tStreamingState::State_Shutdown to tStreamState::State_Constructed.

Use this transition callback to initialize your service by reading properties (of the streaming service itself, not the pins), creation of static pins, opening devices to create valid streamtypes for the pins.

After Construct is called, all pins are requested and connected.

Returns
Returns a standard result code which depends on the implementation.
Return values
ERR_NOERRORSuccessfully constructed
anyError The Streaming Graph will stop constructing.

◆ Destruct()

virtual tResult adtf::streaming::ant::streaming_level_machine::Destruct ( )
inlineprotectedvirtual

Destruct transition while changing from tStreamingState::State_Constructed to tStreamState::State_Shutdown.

Returns
Returns a standard result code which depends on the implementation.

Reimplemented in adtf::streaming::ant::cSampleStreamingSink, and adtf::streaming::ant::cSampleStreamingSource.

◆ Init()

virtual tResult adtf::streaming::ant::streaming_level_machine::Init ( )
inlineprotectedvirtual

Init transition while changing from tStreamingState::State_Constructed to tStreamState::State_Initialized.

Use this transition callback to initialize your service when it depends on the connections. Before Init is called, all pins are requested, connected and their properties are set.

Note
Make sure to call the parent implementation of the used base class at the beginning within your overriding function!
Returns
Returns a standard result code which depends on the implementation.
Return values
ERR_NOERRORSuccessfully constructed
anyError The Streaming Graph will stop initializing.

Reimplemented in adtf::filter::cSampleStreamingSink, and adtf::filter::cSampleStreamingSource.

◆ Shutdown()

virtual tResult adtf::streaming::ant::streaming_level_machine::Shutdown ( )
inlineprotectedvirtual

Shutdown transition while changing from tStreamState::State_Initialized to tStreamingState::State_Constructed.

Note
Make sure to call the parent implementation of the used base class at the end within your overriding function!
Returns
Returns a standard result code which depends on the implementation.

◆ StartStreaming()

virtual tResult adtf::streaming::ant::streaming_level_machine::StartStreaming ( )
inlineprotectedvirtual

StatrStreaming transition while changing from tStreamState::State_Initialized to tStreamingState::State_Streaming.

Use this transition callback to initalize and start threads and timers.

Note
Make sure to call the parent implementation of the used base class at the beginning within your overriding function!
Returns
Returns a standard result code which depends on the implementation.

Reimplemented in adtf::filter::cSampleStreamingSink, adtf::filter::cSampleStreamingSource, adtf::streaming::ant::cSampleStreamingSink, and adtf::streaming::ant::cSampleStreamingSource.

◆ StopStreaming()

virtual tResult adtf::streaming::ant::streaming_level_machine::StopStreaming ( )
inlineprotectedvirtual

StopStreaming transition while changing from tStreamingState::State_Streaming to tStreamState::State_Initialized.

Use this transition callback to stop and destroy threads and timers.

Keep in mind, that streaming and triggers might still occur during and after this function is called. Streaming will only have stopped completely before any other following state change. If your streaming service has any blocking operations during the handling of triggers, make sure that you cancel them in this function.

Note
Make sure to call the parent implementation of the used base class at the end within your overriding function!
Returns
Returns a standard result code which depends on the implementation.
Return values
ERR_NOERRORSuccessfully constructed
anyError The Streaming Graph will stop starting.

Reimplemented in adtf::filter::cSampleStreamingSink, adtf::filter::cSampleStreamingSource, adtf::streaming::ant::cSampleStreamingSink, and adtf::streaming::ant::cSampleStreamingSource.


The documentation for this class was generated from the following file: