TaskProcessor.h
1 /* Distributed under the Apache License, Version 2.0.
2  See accompanying NOTICE file for details.*/
3 
4 #pragma once
5 
6 #include <vector>
7 
8 class Task;
9 class TaskQueue;
10 
11 //--------------------------------------------------------------------------------------------------
15 //--------------------------------------------------------------------------------------------------
17 {
18 public:
19  TaskProcessor(TaskQueue* pTaskQueue);
20  ~TaskProcessor() = default;
21 
22  void operator()();
23 
24 protected:
25  TaskQueue* m_pTaskQueue = nullptr;
26 };
void operator()()
Parenthesis operator that draws and runs Tasks until the TaskQueue is empty.
Definition: TaskProcessor.cpp:24
TaskQueue * m_pTaskQueue
Pointer to the TaskQueue to draw Tasks from.
Definition: TaskProcessor.h:25
TaskProcessor(TaskQueue *pTaskQueue)
Constructor.
Definition: TaskProcessor.cpp:15
This class is a functor used in threads launched by the TaskRunner. It&#39;s responsibility is to pull an...
Definition: TaskProcessor.h:16
Interface from which tasks used in the TaskRunner should derive.
Definition: Task.h:10
Interface through which TaskProcessors retrieve Tasks from the TaskRunner.
Definition: TaskQueue.h:13
~TaskProcessor()=default