|
| | TQueue () noexcept=default |
| | The default class constructor.
|
| | TQueue (const TQueue< T, TAlloc > &rhs) |
| | The class copy constructor.
|
| | ~TQueue () |
| | The destructor.
|
| void | enqueue (const T &item) |
| | A new item will be enqueued.
|
| bool | dequeue (T &item) |
| | Tries to dequeue the next item from the queue.
|
| T | front () |
| | Returns the first item of the queue.
|
| bool | isEmpty () const |
| | Returns true, if the queue is empty.
|
| size_t | size () |
| | The number of enqueued items will be returned.
|
| void | clear () |
| | The queue will be cleared.
|
| TQueue< T, TAlloc > & | operator= (const TQueue< T, TAlloc > &rhs) |
| | The assignment operator.
|
| bool | operator== (const TQueue< T, TAlloc > &rhs) const |
| | The compare operator.
|
template<class T, class TAlloc = TDefaultAllocator<T>>
class cppcore::TQueue< T, TAlloc >
This template class implements a simple queue ( works FIFO ).
Definition at line 37 of file TQueue.h.
template<class T, class TAlloc>
Tries to dequeue the next item from the queue.
If no more items are there, false will be returned. If the queue is empty, this will fail.
- Parameters
-
| item | [ out ] The next item, if true was returned. |
- Returns
- true, if an item was dequeued correctly, false if the queue was already empty.
Definition at line 101 of file TQueue.h.
References isEmpty().
Referenced by TQueue().