boost::pipeline::queue_front
// In header: <boost/pipeline/queue.hpp> template<typename T> class queue_front { public: // types typedef queue< T >::value_type value_type; // construct/copy/destruct queue_front(queue< T > &); // public member functions bool wait_pull(T &); bool is_empty() const; bool is_closed() const; };
Consumer handle to a buffer queue between segments.
Each transformation consuming multiple items on each call receive a queue_front
instance which is used to access to the upstream queue.
A handle is valid until the segment which owns the input queue terminates.
Template arguments:
T Value type of the underlying queue
queue_front
public member functionsbool wait_pull(T & ret);
Pulls the front item of the queue.
Blocks until an item becomes available or the underlying queue gets closed.
Parameters: |
|
||
Returns: |
true, if pulled successfully, false otherwise (queue is closed) |
bool is_empty() const;
Checks the underlying queue for emptiness.
This call is subject to race.
Returns: |
true, if the queue was empty, false otherwise |
bool is_closed() const;
Checks whether the underlying queue is closed.
Returns: |
true, if the queue is closed, false otherwise |