Hedgehog  3.1.0
A library to generate hybrid pipeline workflow systems
Loading...
Searching...
No Matches
hh::behavior::TaskMultiSenders< Outputs > Class Template Reference

Behavior abstraction for tasks that send multiple types of data. More...

#include "task_multi_senders.h"

Inheritance diagram for hh::behavior::TaskMultiSenders< Outputs >:
Inheritance graph
Collaboration diagram for hh::behavior::TaskMultiSenders< Outputs >:
Collaboration graph

Public Member Functions

template<tool::MultiSendersAndNotifierAbstractionConcept MultiSendersAndNotifier>
 TaskMultiSenders (std::shared_ptr< MultiSendersAndNotifier > abstraction)
 Default constructor.
 
virtual ~TaskMultiSenders ()=default
 Default destructor.
 
- Public Member Functions inherited from hh::behavior::MultiSenders< Outputs... >
 MultiSenders ()=default
 Default constructor.
 
virtual ~MultiSenders ()=default
 Default destructor.
 

Protected Member Functions

template<tool::MatchOutputTypeConcept< Outputs... > DataType>
void addResult (std::shared_ptr< DataType > data)
 Add result and send it to the task successors.
 

Private Attributes

std::shared_ptr< core::abstraction::TaskOutputsManagementAbstraction< Outputs... > > tom_ = nullptr
 Link to the task's core TaskOutputsManagementAbstraction.
 

Additional Inherited Members

- Public Types inherited from hh::behavior::MultiSenders< Outputs... >
using outputs_t = std::tuple< Outputs... >
 Accessor of output data type.
 

Detailed Description

template<class ... Outputs>
class hh::behavior::TaskMultiSenders< Outputs >

Behavior abstraction for tasks that send multiple types of data.

Template Parameters
OutputsTypes of data the task sends

Definition at line 35 of file task_multi_senders.h.

Constructor & Destructor Documentation

◆ TaskMultiSenders()

template<class ... Outputs>
template<tool::MultiSendersAndNotifierAbstractionConcept MultiSendersAndNotifier>
hh::behavior::TaskMultiSenders< Outputs >::TaskMultiSenders ( std::shared_ptr< MultiSendersAndNotifier >  abstraction)
inlineexplicit

Default constructor.

Template Parameters
MultiSendersAndNotifierType of core that has to implement TaskOutputsManagementAbstraction
Parameters
abstractionCore's abstraction of type MultiSendersAndNotifier
Exceptions
std::runtime_errorThe abstraction is not valid (== nullptr)

Definition at line 46 of file task_multi_senders.h.

◆ ~TaskMultiSenders()

template<class ... Outputs>
virtual hh::behavior::TaskMultiSenders< Outputs >::~TaskMultiSenders ( )
virtualdefault

Default destructor.

Member Function Documentation

◆ addResult()

template<class ... Outputs>
template<tool::MatchOutputTypeConcept< Outputs... > DataType>
void hh::behavior::TaskMultiSenders< Outputs >::addResult ( std::shared_ptr< DataType >  data)
inlineprotected

Add result and send it to the task successors.

Template Parameters
DataTypeType of the data, should be part of the task Output types
Parameters
dataData of type DataType sent to the task successors
Exceptions
std::runtime_errorThe TaskOutputsManagementAbstraction abstraction is not initialized (== nullptr)

Definition at line 63 of file task_multi_senders.h.

Member Data Documentation

◆ tom_

template<class ... Outputs>
std::shared_ptr<core::abstraction::TaskOutputsManagementAbstraction<Outputs...> > hh::behavior::TaskMultiSenders< Outputs >::tom_ = nullptr
private

Link to the task's core TaskOutputsManagementAbstraction.

Definition at line 38 of file task_multi_senders.h.