Struct heapless::spsc::Producer [−][src]
pub struct Producer<'a, T, const N: usize> { /* fields omitted */ }
Expand description
A queue “producer”; it can enqueue items into the queue
NOTE the producer semantically owns the tail
pointer of the queue
Implementations
Adds an item
to the end of the queue, returns back the item
if the queue is full
Adds an item
to the end of the queue, without checking if the queue is full
See Queue::enqueue_unchecked
for safety
Returns if there is any space to enqueue a new item. When this returns true, at least the first subsequent enqueue will succeed.