21#ifndef HEDGEHOG_TASK_OUTPUTS_MANAGEMENT_ABSTRACTION_H
22#define HEDGEHOG_TASK_OUTPUTS_MANAGEMENT_ABSTRACTION_H
26#include "../../../api/printer/printer.h"
27#include "../base/input_output/notifier_abstraction.h"
28#include "../base/input_output/receiver_abstraction.h"
30#include "../../implementors/concrete_implementor/default_notifier.h"
31#include "../../implementors/concrete_implementor/default_sender.h"
33#include "../../../tools/concepts.h"
40namespace abstraction {
44template<
class ...Outputs>
52 SenderAbstraction<Outputs>(std::make_shared<implementor::DefaultSender<Outputs>>())... {}
60 std::shared_ptr<implementor::ImplementorNotifier> concreteNotifier,
61 std::shared_ptr<ConcreteMultiSenders> concreteMultiSenders)
Core abstraction to notify slots.
void duplicateEdgeNotifier(std::map< abstraction::NodeAbstraction *, std::shared_ptr< NodeAbstraction > > &mapping)
Duplicate edges of the current notifier to slots to clone in map.
void notify()
Notify a slot to wake up.
Core abstraction to send data.
void duplicateEdgeSender(std::map< abstraction::NodeAbstraction *, std::shared_ptr< NodeAbstraction > > &mapping)
Duplicate edges of the current sender to receiver to clone in map.
void copyInnerStructure(SenderAbstraction< Output > *copyableCore)
Copy inner structure of the sender to this one.
void send(std::shared_ptr< Outputs > data)
Send a data as output of the node.
Base core node abstraction.
Output management abstraction for the task.
void copyInnerStructure(TaskOutputsManagementAbstraction< Outputs... > *copyableCore)
Copy the inner structure from another task.
~TaskOutputsManagementAbstraction() override=default
Default destructor.
void duplicateOutputEdges(std::map< abstraction::NodeAbstraction *, std::shared_ptr< NodeAbstraction > > &mapping)
Duplicate the output edges for the node clone.
void sendAndNotify(std::shared_ptr< OutputDataType > data)
Send a piece of data and notify the successors.
TaskOutputsManagementAbstraction(std::shared_ptr< implementor::ImplementorNotifier > concreteNotifier, std::shared_ptr< ConcreteMultiSenders > concreteMultiSenders)
Constructor using concrete implementation of the possible core abstraction.
TaskOutputsManagementAbstraction()
Default constructor.
std::tuple< Outputs... > outputs_t
Accessor to the graph outputs type.
Concept verifying that a type is in a variadic.
Test if a type is a valid concrete implementation of the core::implementor::ImplementorSender for the...