|
Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
|
#include <q-consumer-threads.H>
Public Member Functions | |
| virtual void | run ()=0 |
| this is a item extracted from the queue | |
| size_t | get_count () const noexcept |
| void | increment_count () noexcept |
| virtual | ~ConsumerQueueEvent () |
Public Attributes | |
| T | item |
Protected Attributes | |
| std::atomic< size_t > | count = 0 |
Private Types | |
| enum class | Status { Ready , Executing } |
Private Attributes | |
| Status | status = Status::Ready |
Friends | |
| class | QueueTheadsPool |
Definition at line 90 of file q-consumer-threads.H.
|
strongprivate |
| Enumerator | |
|---|---|
| Ready | |
| Executing | |
Definition at line 94 of file q-consumer-threads.H.
|
inlinevirtual |
Definition at line 120 of file q-consumer-threads.H.
|
inlinenoexcept |
Definition at line 116 of file q-consumer-threads.H.
References QueueTheadsPool< T >::ConsumerQueueEvent::count.
|
inlinenoexcept |
Definition at line 118 of file q-consumer-threads.H.
References QueueTheadsPool< T >::ConsumerQueueEvent::count.
Referenced by Event1::run(), and Event2::run().
this is a item extracted from the queue
Derived classes from this one implement the action that must performed when the item is extracted from the queue.
After event execution this event return a bool. A true return value indicates that the thread can continue consuming others items form the queue. At the contrary, a false return value indicates that the thread must finish
|
friend |
Definition at line 92 of file q-consumer-threads.H.
|
protected |
Definition at line 100 of file q-consumer-threads.H.
Referenced by QueueTheadsPool< T >::ConsumerQueueEvent::get_count(), and QueueTheadsPool< T >::ConsumerQueueEvent::increment_count().
| T QueueTheadsPool< T >::ConsumerQueueEvent::item |
Definition at line 104 of file q-consumer-threads.H.
|
private |
Definition at line 96 of file q-consumer-threads.H.