#include <concurrency.hpp>
Public Member Functions | |
void | clear () |
T | dequeue () |
void | enqueue (T item) |
single_consumer_queue () | |
size_t | size () |
bool | try_dequeue (T *item) |
Private Attributes | |
std::condition_variable | cv |
std::mutex | mutex |
std::queue< T > | q |
Definition at line 11 of file concurrency.hpp.
single_consumer_queue< T >::single_consumer_queue | ( | ) | [inline] |
Definition at line 18 of file concurrency.hpp.
void single_consumer_queue< T >::clear | ( | ) | [inline] |
Definition at line 51 of file concurrency.hpp.
T single_consumer_queue< T >::dequeue | ( | ) | [inline] |
Definition at line 28 of file concurrency.hpp.
void single_consumer_queue< T >::enqueue | ( | T | item | ) | [inline] |
Definition at line 20 of file concurrency.hpp.
size_t single_consumer_queue< T >::size | ( | ) | [inline] |
Definition at line 64 of file concurrency.hpp.
bool single_consumer_queue< T >::try_dequeue | ( | T * | item | ) | [inline] |
Definition at line 38 of file concurrency.hpp.
std::condition_variable single_consumer_queue< T >::cv [private] |
Definition at line 15 of file concurrency.hpp.
std::mutex single_consumer_queue< T >::mutex [private] |
Definition at line 14 of file concurrency.hpp.
std::queue<T> single_consumer_queue< T >::q [private] |
Definition at line 13 of file concurrency.hpp.