#include <TaskScheduler.h>

Base class for a task scheduler
The API allows to:
Public Member Functions | |
| virtual | ~TaskScheduler ()=default |
| virtual void | init (const unsigned int nbThread=0)=0 |
| virtual void | stop (void)=0 |
| virtual unsigned int | getThreadCount (void) const =0 |
| virtual const char * | getCurrentThreadName ()=0 |
| virtual int | getCurrentThreadType ()=0 |
| virtual bool | addTask (Task *task)=0 |
| virtual bool | addTask (Task::Status &status, const std::function< void()> &task) |
| virtual void | workUntilDone (Task::Status *status)=0 |
| virtual Task::Allocator * | getTaskAllocator ()=0 |
Static Public Member Functions | |
| static unsigned | GetHardwareThreadsCount () |
Friends | |
| class | Task |
|
virtualdefault |
Implemented in sofa::simulation::DefaultTaskScheduler.
|
virtual |
|
pure virtual |
Implemented in sofa::simulation::DefaultTaskScheduler.
|
pure virtual |
Implemented in sofa::simulation::DefaultTaskScheduler.
|
static |
Assuming 2 concurrent threads by CPU core, return the number of CPU core on the system
|
pure virtual |
Implemented in sofa::simulation::DefaultTaskScheduler.
Implemented in sofa::simulation::DefaultTaskScheduler.
Implemented in sofa::simulation::DefaultTaskScheduler.
|
pure virtual |
Implemented in sofa::simulation::DefaultTaskScheduler.
|
pure virtual |
Implemented in sofa::simulation::DefaultTaskScheduler.
|
friend |