An intrusive, thread-safe LIFO queue implementation for a single reader with any number of writers.
More...
|
| inbox_result | push_front (pointer new_element) noexcept |
| | Tries to enqueue a new element to the inbox.
|
| |
| inbox_result | push_front (unique_pointer x) noexcept |
| | Tries to enqueue a new element to the inbox.
|
| |
| template<class... Ts> |
| inbox_result | emplace_front (Ts &&... xs) |
| | Tries to enqueue a new element to the mailbox.
|
| |
| bool | empty () const noexcept |
| | Queries whether this queue is empty.
|
| |
|
bool | closed () const noexcept |
| | Queries whether this has been closed.
|
| |
|
bool | blocked () const noexcept |
| | Queries whether this has been marked as blocked, i.e., the owner of the list is waiting for new data.
|
| |
|
bool | try_block () noexcept |
| | Tries to set this queue from empty to blocked.
|
| |
|
bool | try_unblock () noexcept |
| | Tries to set this queue from blocked to empty.
|
| |
|
pointer | take_head (pointer new_head) noexcept |
| | Sets the head to new_head and returns the previous head if the queue was not empty.
|
| |
|
pointer | take_head () noexcept |
| | Sets the head to stack_empty_tag() and returns the previous head if the queue was not empty.
|
| |
| void | close () noexcept |
| | Closes this queue and deletes all remaining elements.
|
| |
| template<class F > |
| void | close (F &f) noexcept(noexcept(f(std::declval< pointer >()))) |
| | Closes this queue and applies f to each pointer.
|
| |
|
template<class Mutex , class CondVar > |
| bool | synchronized_push_front (Mutex &mtx, CondVar &cv, pointer ptr) |
| |
|
template<class Mutex , class CondVar > |
| bool | synchronized_push_front (Mutex &mtx, CondVar &cv, unique_pointer ptr) |
| |
|
template<class Mutex , class CondVar , class... Ts> |
| bool | synchronized_emplace_front (Mutex &mtx, CondVar &cv, Ts &&... xs) |
| |
|
template<class Mutex , class CondVar > |
| void | synchronized_await (Mutex &mtx, CondVar &cv) |
| |
|
template<class Mutex , class CondVar , class TimePoint > |
| bool | synchronized_await (Mutex &mtx, CondVar &cv, const TimePoint &timeout) |
| |
template<
class Policy>
class caf::intrusive::lifo_inbox< Policy >
An intrusive, thread-safe LIFO queue implementation for a single reader with any number of writers.