Hedgehog  3.1.0
A library to generate hybrid pipeline workflow systems
Loading...
Searching...
No Matches
hh::Scheduler Class Referenceabstract

Scheduler abstraction to manage graph's threads. More...

#include "scheduler.h"

Inheritance diagram for hh::Scheduler:
Inheritance graph
Collaboration diagram for hh::Scheduler:
Collaboration graph

Public Member Functions

 Scheduler ()=default
 Scheduler default constructor.
 
virtual ~Scheduler ()=default
 Scheduler default destructor.
 
virtual std::unique_ptr< Schedulercreate () const =0
 Definition of virtual constructor.
 
virtual void spawnThreads (std::set< core::abstraction::NodeAbstraction * > const &cores, bool waitForInitialization)=0
 Spawn the threads of a graph.
 
virtual void joinAll ()=0
 Method waiting for all graph's threads termination, called when Graph::waitForTermination() is called.
 

Detailed Description

Scheduler abstraction to manage graph's threads.

Definition at line 32 of file scheduler.h.

Constructor & Destructor Documentation

◆ Scheduler()

hh::Scheduler::Scheduler ( )
default

Scheduler default constructor.

◆ ~Scheduler()

virtual hh::Scheduler::~Scheduler ( )
virtualdefault

Scheduler default destructor.

Member Function Documentation

◆ create()

virtual std::unique_ptr< Scheduler > hh::Scheduler::create ( ) const
pure virtual

Definition of virtual constructor.

Returns
New instance of Scheduler

Implemented in hh::DefaultScheduler.

◆ joinAll()

virtual void hh::Scheduler::joinAll ( )
pure virtual

Method waiting for all graph's threads termination, called when Graph::waitForTermination() is called.

Implemented in hh::DefaultScheduler.

◆ spawnThreads()

virtual void hh::Scheduler::spawnThreads ( std::set< core::abstraction::NodeAbstraction * > const &  cores,
bool  waitForInitialization 
)
pure virtual

Spawn the threads of a graph.

Parameters
coresCores of every nodes in a graph
waitForInitializationWait for internal nodes to be initialized flags

Implemented in hh::DefaultScheduler.