Struct crtq::Consumer [−][src]
pub struct Consumer<T>(_, _);
A consumer for an unbounded MPMC wait-free queue.
Methods
impl<T> Consumer<T>
[src]
impl<T> Consumer<T>
pub fn consume(&self) -> Result<T, ConsumeError>
[src]
pub fn consume(&self) -> Result<T, ConsumeError>
Attempts to remove and return the item at the front of the queue.
This method returns Err
if the queue is empty.
pub fn try_clone(&self) -> Option<Self>
[src]
pub fn try_clone(&self) -> Option<Self>
Attempts to clone this consumer.
Trait Implementations
impl<T: Debug> Debug for Consumer<T>
[src]
impl<T: Debug> Debug for Consumer<T>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<T> Clone for Consumer<T>
[src]
impl<T> Clone for Consumer<T>
fn clone(&self) -> Self
[src]
fn clone(&self) -> Self
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl<T> Drop for Consumer<T>
[src]
impl<T> Drop for Consumer<T>
impl<T> Send for Consumer<T> where
T: Send,
[src]
impl<T> Send for Consumer<T> where
T: Send,