DubiousEngine
0.2.0
Simple Game Engine
|
Simple thread pool. More...
#include <Thread_pool.h>
Public Types | |
typedef std::function< void()> | Func |
Public Member Functions | |
Thread_pool (const int pool_size) | |
~Thread_pool () | |
void | push (Func f) |
int | size () const |
Simple thread pool.
This is a simple queue of work and a pool of threads to do the work. It's not terribly sophisticated, and it actually may not work correctly as it's not in use at the moment. I am playing with threading and C++11 async, so this might go away.
DO NOT USE Unless appropriately tested, debugged, etc
typedef std::function<void()> Dubious::Utility::Thread_pool::Func |
Dubious::Utility::Thread_pool::Thread_pool | ( | const int | pool_size | ) |
Dubious::Utility::Thread_pool::~Thread_pool | ( | ) |
void Dubious::Utility::Thread_pool::push | ( | Func | f | ) |
int Dubious::Utility::Thread_pool::size | ( | ) | const |