A simple thread pool that pulls tasks off its queue in FIFO order.
More...
#include <ThreadPool.h>
|
| ThreadPool (std::size_t numThreads) |
| Constructs a thread pool with numThreads threads.
|
|
| ~ThreadPool () |
| Finishes all tasks currently in the queue.
|
|
void | add (std::function< void()> task) |
|
| ThreadPool (std::size_t numThreads) |
| Constructs a thread pool with numThreads threads.
|
|
| ~ThreadPool () |
| Finishes all tasks currently in the queue.
|
|
void | add (std::function< void()> task) |
|
| ThreadPool (std::size_t numThreads) |
| Constructs a thread pool with numThreads threads.
|
|
| ~ThreadPool () |
| Finishes all tasks currently in the queue.
|
|
void | add (std::function< void()> task) |
|
A simple thread pool that pulls tasks off its queue in FIFO order.
◆ ThreadPool() [1/3]
Constructs a thread pool with numThreads
threads.
◆ ~ThreadPool() [1/3]
Finishes all tasks currently in the queue.
◆ ThreadPool() [2/3]
Constructs a thread pool with numThreads
threads.
◆ ~ThreadPool() [2/3]
Finishes all tasks currently in the queue.
◆ ThreadPool() [3/3]
Constructs a thread pool with numThreads
threads.
◆ ~ThreadPool() [3/3]
Finishes all tasks currently in the queue.
◆ add() [1/3]
void add |
( |
std::function< void()> | task | ) |
|
|
inline |
Adds task
to the queue of tasks to execute. Since task
is a std::function<>
, it cannot be a move only type. So any lambda passed must not capture move only types (like std::unique_ptr
).
- Parameters
-
◆ add() [2/3]
void add |
( |
std::function< void()> | task | ) |
|
|
inline |
Adds task
to the queue of tasks to execute. Since task
is a std::function<>
, it cannot be a move only type. So any lambda passed must not capture move only types (like std::unique_ptr
).
- Parameters
-
◆ add() [3/3]
void add |
( |
std::function< void()> | task | ) |
|
|
inline |
Adds task
to the queue of tasks to execute. Since task
is a std::function<>
, it cannot be a move only type. So any lambda passed must not capture move only types (like std::unique_ptr
).
- Parameters
-
The documentation for this class was generated from the following files:
- C:/Pereira/Dua/source forge files my love/tar_dll/val/xcx_Zstandard/zstd-1.5.2/contrib/pzstd/utils/ThreadPool.h
- C:/Pereira/Dua/source forge files my love/tar_dll/val/xcx_Zstandard/zstd-1.5.5/contrib/pzstd/utils/ThreadPool.h
- C:/Pereira/Dua/source forge files my love/tar_dll/val/xcx_Zstandard/zstd-1.5.6/contrib/pzstd/utils/ThreadPool.h