proxygen
|
#include <LifoSemMPMCQueue.h>
Public Member Functions | |
LifoSemMPMCQueue (size_t max_capacity) | |
BlockingQueueAddResult | add (T item) override |
T | take () override |
folly::Optional< T > | try_take_for (std::chrono::milliseconds time) override |
size_t | capacity () |
size_t | size () override |
Public Member Functions inherited from folly::BlockingQueue< T > | |
virtual | ~BlockingQueue ()=default |
virtual BlockingQueueAddResult | addWithPriority (T item, int8_t) |
virtual uint8_t | getNumPriorities () |
Private Attributes | |
folly::LifoSem | sem_ |
folly::MPMCQueue< T > | queue_ |
Definition at line 26 of file LifoSemMPMCQueue.h.
|
inlineexplicit |
Definition at line 29 of file LifoSemMPMCQueue.h.
|
inlineoverridevirtual |
Implements folly::BlockingQueue< T >.
Definition at line 31 of file LifoSemMPMCQueue.h.
References folly::BLOCK, folly::gen::move, folly::detail::LifoSemBase< Handoff, Atom >::post(), folly::LifoSemMPMCQueue< T, kBehavior >::queue_, folly::LifoSemMPMCQueue< T, kBehavior >::sem_, and folly::THROW.
|
inline |
Definition at line 63 of file LifoSemMPMCQueue.h.
References folly::LifoSemMPMCQueue< T, kBehavior >::queue_.
|
inlineoverridevirtual |
Implements folly::BlockingQueue< T >.
Definition at line 67 of file LifoSemMPMCQueue.h.
References folly::LifoSemMPMCQueue< T, kBehavior >::queue_.
|
inlineoverridevirtual |
Implements folly::BlockingQueue< T >.
Definition at line 45 of file LifoSemMPMCQueue.h.
References folly::LifoSemMPMCQueue< T, kBehavior >::queue_, folly::LifoSemMPMCQueue< T, kBehavior >::sem_, folly::T, and folly::detail::LifoSemBase< Handoff, Atom >::wait().
|
inlineoverridevirtual |
Implements folly::BlockingQueue< T >.
Definition at line 53 of file LifoSemMPMCQueue.h.
References folly::gen::move, folly::none, folly::LifoSemMPMCQueue< T, kBehavior >::queue_, folly::LifoSemMPMCQueue< T, kBehavior >::sem_, folly::T, and folly::detail::LifoSemBase< Handoff, Atom >::try_wait_for().
|
private |
Definition at line 73 of file LifoSemMPMCQueue.h.
Referenced by folly::LifoSemMPMCQueue< T, kBehavior >::add(), folly::LifoSemMPMCQueue< T, kBehavior >::capacity(), folly::LifoSemMPMCQueue< T, kBehavior >::size(), folly::LifoSemMPMCQueue< T, kBehavior >::take(), and folly::LifoSemMPMCQueue< T, kBehavior >::try_take_for().
|
private |
Definition at line 72 of file LifoSemMPMCQueue.h.
Referenced by folly::LifoSemMPMCQueue< T, kBehavior >::add(), folly::LifoSemMPMCQueue< T, kBehavior >::take(), and folly::LifoSemMPMCQueue< T, kBehavior >::try_take_for().