This class implements a thread pool used for concurrently executing multiple user‐defined functions ("jobs").
Synopsis
Declared in <bdlmt_fixedthreadpool.h>
class FixedThreadPool;
Type Aliases
Enums
Name |
Description |
Status codes returned by queue operations. |
|
Thread‐pool operational states. |
Member Functions
Name |
Description |
|
Constructors |
|
Remove all pending jobs from the queue without executing them, block until all currently running jobs complete, and then destroy this thread pool. |
Disable enqueueing into this pool. All subsequent invocations of |
|
Wait until the underlying queue is empty without disabling this pool (and may thus wait indefinitely), and then wait until all executing jobs complete. If the thread pool was not already started ( |
|
Enable queuing into this pool. If the queue is not enqueue disabled, this call has no effect. |
|
|
|
Return |
|
Return |
|
Return a snapshot of the number of threads that are currently processing a job for this threadpool. |
|
Return a snapshot of the number of jobs currently enqueued to be processed by thread pool. |
|
Return the number of threads passed to this thread pool at construction. |
|
Return a snapshot of the number of threads currently started by this thread pool. |
|
Return the capacity of the queue used to enqueue jobs by this thread pool. |
|
Disable enqueuing jobs on this thread pool, cancel all pending jobs, wait until all active jobs complete, and join all processing threads. If the thread pool was not already started ( |
|
Spawn threads until there are |
|
Disable enqueuing jobs on this thread pool, wait until all active and pending jobs complete, and join all processing threads. If the thread pool was not already started ( |
|
|
Created with MrDocs