Inheritance diagram for concurrent::GenericQueue< T, QueuePolicy >::SingleConsumerSide:Public Types | |
| using | ValueType |
| using | Producer |
| using | Consumer |
| using | MultiProducer |
| using | MultiConsumer |
Public Member Functions | |
| SingleConsumerSide (GenericQueue &queue) | |
| template<typename Token> | |
| bool | Pop (Token &token, T &value, engine::Deadline deadline) |
| template<typename Token> | |
| bool | PopNoblock (Token &token, T &value) |
| void | OnElementPushed () |
| void | StopBlockingOnPop () |
| void | ResumeBlockingOnPop () |
| std::size_t | GetElementCount () const |
| Producer | GetProducer () |
| MultiProducer | GetMultiProducer () |
| Consumer | GetConsumer () |
| MultiConsumer | GetMultiConsumer () |
| void | SetSoftMaxSize (std::size_t max_size) |
| Sets the limit on the queue size, pushes over this limit will block. | |
| std::size_t | GetSoftMaxSize () const |
| Gets the limit on the queue size. | |
| std::size_t | GetSizeApproximate () const |
| Gets the approximate size of queue. | |
Static Public Member Functions | |
| static std::shared_ptr< GenericQueue > | Create (std::size_t max_size=kUnbounded) |
| Create a new queue. | |
Static Public Attributes | |
| static constexpr std::size_t | kUnbounded |
| using concurrent::GenericQueue< T, QueuePolicy >::Consumer |
| using concurrent::GenericQueue< T, QueuePolicy >::MultiConsumer |
| using concurrent::GenericQueue< T, QueuePolicy >::MultiProducer |
| using concurrent::GenericQueue< T, QueuePolicy >::Producer |
| using concurrent::GenericQueue< T, QueuePolicy >::ValueType |
|
inlineexplicit |
|
inlinestatic |
|
inline |
Get a Consumer which makes it possible to read items from the queue. Can be called multiple times. The resulting Consumer is not thread-safe, so you have to use multiple Consumers of the same queue to simultaneously write from multiple coroutines/threads.
Consumer may outlive the queue and producers.
|
inline |
|
inline |
Get a MultiConsumer which makes it possible to read items from the queue. Can be called multiple times. The resulting MultiConsumer is thread-safe, so it can be used simultaneously from multiple coroutines/threads.
MultiConsumer may outlive the queue and producers.Consumer tokens when possible, because MultiConsumer token incurs some overhead.
|
inline |
Get a MultiProducer which makes it possible to push items into the queue. Can be called multiple times. The resulting MultiProducer is thread-safe, so it can be used simultaneously from multiple coroutines/threads.
MultiProducer may outlive the queue and consumers.Producer tokens when possible, because MultiProducer token incurs some overhead.
|
inline |
Get a Producer which makes it possible to push items into the queue. Can be called multiple times. The resulting Producer is not thread-safe, so you have to use multiple Producers of the same queue to simultaneously write from multiple coroutines/threads.
Producer may outlive the queue and consumers.
|
inline |
|
inline |
|
inline |
|
inlinenodiscard |
|
inlinenodiscard |
|
inline |
|
inline |
|
inline |
|
friend |
|
friend |
|
friend |
|
friend |
|
staticconstexpr |