Struct itron_solid_asp3::dataqueue::Dataqueue [−][src]
pub struct Dataqueue(_);
This is supported on crate features
unstable
and dcre
only.Expand description
An owned dataqueue.
Deletes the dataqueue automatically when dropped. The destructor will panic if the deletion fails.
Implementations
acre_dtq
: Create a builder for Dataqueue
.
Examples
use itron::dataqueue::Dataqueue;
let dataqueue = Dataqueue::build()
.capacity(2)
.finish()
.expect("failed to create a dataqueue");
dataqueue.as_ref().send(1)
.expect("failed to send a data element");
dataqueue.as_ref().send(2)
.expect("failed to send a data element");
dataqueue.as_ref().try_send(3)
.expect_err("unexpectedly succeeded to send a data element");
Consume and “leak” self
, returning a reference DataqueueRef<'a>
.
Get the raw object ID as abi::NonNullID
.
Borrow Dataqueue
as DataqueueRef
.
Use this to perform operations on dataqueues because most of the
methods are implemented on DataqueueRef
but not Dataqueue
.