![]() |
ROOT
6.06/09
Reference Guide
|
Definition at line 118 of file TThreadPool.h.
Public Member Functions | |
| TThreadPool (size_t threadsCount, bool needDbg=false) | |
| ~TThreadPool () | |
| void | AddThread () |
| void | PushTask (typename TThreadPoolTask< aTask, aParam >::task_t &task, aParam param) |
| void | Stop (bool processRemainingJobs=false) |
| void | Drain () |
| size_t | TasksCount () const |
| size_t | SuccessfulTasks () const |
| size_t | IdleThreads () const |
Private Types | |
| typedef TThreadPoolTask< aTask, aParam > | task_t |
| typedef std::queue< task_t * > | taskqueue_t |
| typedef std::vector< TThread * > | threads_array_t |
Private Member Functions | |
| void | DbgLog (const std::string &msg) |
Static Private Member Functions | |
| static void * | Monitor (void *arg) |
| static void * | Executor (void *arg) |
| static void * | JoinHelper (void *arg) |
| static bool | IsThreadActive (TThread *pThread) |
Private Attributes | |
| taskqueue_t | fTasks |
| TMutex | fMutex |
| TCondition * | fThreadNeeded |
| TCondition * | fThreadAvailable |
| TMutex | fMutexAllTasksDone |
| TCondition * | fAllTasksDone |
| threads_array_t | fThreads |
| TThread * | fThreadJoinHelper |
| TThread * | fThreadMonitor |
| volatile bool | fStopped |
| size_t | fSuccessfulTasks |
| size_t | fTasksCount |
| size_t | fIdleThreads |
| TMutex | fDbgOutputMutex |
| bool | fSilent |
Additional Inherited Members | |
Protected Member Functions inherited from TNonCopyable | |
| TNonCopyable () | |
| ~TNonCopyable () | |
#include <TThreadPool.h>
Inheritance diagram for TThreadPool< aTask, aParam >:
Collaboration diagram for TThreadPool< aTask, aParam >:
|
private |
Definition at line 120 of file TThreadPool.h.
|
private |
Definition at line 121 of file TThreadPool.h.
|
private |
Definition at line 122 of file TThreadPool.h.
|
inline |
Definition at line 125 of file TThreadPool.h.
|
inline |
Definition at line 149 of file TThreadPool.h.
|
inline |
Definition at line 164 of file TThreadPool.h.
|
inlineprivate |
Definition at line 331 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Executor(), TThreadPool< aTask, aParam >::Monitor(), TThreadPool< aTask, aParam >::PushTask(), and TThreadPool< aTask, aParam >::Stop().
|
inline |
Definition at line 214 of file TThreadPool.h.
|
inlinestaticprivate |
Definition at line 251 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::AddThread(), and TThreadPool< aTask, aParam >::TThreadPool().
|
inline |
Definition at line 229 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Monitor().
|
inlinestaticprivate |
Definition at line 326 of file TThreadPool.h.
|
inlinestaticprivate |
Definition at line 316 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::TThreadPool().
|
inlinestaticprivate |
Definition at line 234 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::TThreadPool().
|
inline |
Definition at line 172 of file TThreadPool.h.
|
inline |
Definition at line 187 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::~TThreadPool().
|
inline |
Definition at line 225 of file TThreadPool.h.
|
inline |
Definition at line 221 of file TThreadPool.h.
|
private |
Definition at line 344 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Drain(), TThreadPool< aTask, aParam >::Executor(), TThreadPool< aTask, aParam >::TThreadPool(), and TThreadPool< aTask, aParam >::~TThreadPool().
|
private |
Definition at line 352 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::DbgLog().
|
private |
Definition at line 351 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::AddThread(), TThreadPool< aTask, aParam >::Executor(), and TThreadPool< aTask, aParam >::IdleThreads().
|
private |
Definition at line 340 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::AddThread(), TThreadPool< aTask, aParam >::Executor(), TThreadPool< aTask, aParam >::PushTask(), TThreadPool< aTask, aParam >::Stop(), and TThreadPool< aTask, aParam >::TThreadPool().
|
private |
Definition at line 343 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Drain(), TThreadPool< aTask, aParam >::Executor(), and TThreadPool< aTask, aParam >::TThreadPool().
|
private |
Definition at line 353 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::DbgLog().
|
private |
Definition at line 348 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Executor(), TThreadPool< aTask, aParam >::Monitor(), and TThreadPool< aTask, aParam >::Stop().
|
private |
Definition at line 349 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Executor(), and TThreadPool< aTask, aParam >::SuccessfulTasks().
|
private |
Definition at line 339 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Executor(), TThreadPool< aTask, aParam >::Monitor(), TThreadPool< aTask, aParam >::PushTask(), and TThreadPool< aTask, aParam >::Stop().
|
private |
Definition at line 350 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::PushTask(), and TThreadPool< aTask, aParam >::TasksCount().
|
private |
Definition at line 342 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Executor(), TThreadPool< aTask, aParam >::Stop(), TThreadPool< aTask, aParam >::TThreadPool(), and TThreadPool< aTask, aParam >::~TThreadPool().
|
private |
Definition at line 346 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Stop(), TThreadPool< aTask, aParam >::TThreadPool(), and TThreadPool< aTask, aParam >::~TThreadPool().
|
private |
Definition at line 347 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::TThreadPool().
|
private |
Definition at line 341 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::Executor(), TThreadPool< aTask, aParam >::PushTask(), TThreadPool< aTask, aParam >::Stop(), TThreadPool< aTask, aParam >::TThreadPool(), and TThreadPool< aTask, aParam >::~TThreadPool().
|
private |
Definition at line 345 of file TThreadPool.h.
Referenced by TThreadPool< aTask, aParam >::AddThread(), TThreadPool< aTask, aParam >::Executor(), TThreadPool< aTask, aParam >::JoinHelper(), TThreadPool< aTask, aParam >::TThreadPool(), and TThreadPool< aTask, aParam >::~TThreadPool().