pub enum TryRecvError {
Empty,
Closed,
Lagged(u64),
}Variants§
Empty
The channel is currently empty. There are still active
Sender handles, so data may yet become available.
Closed
There are no more active senders implying no further messages will ever be sent.
Lagged(u64)
The receiver lagged too far behind: one or more messages were overwritten in the ring buffer before this receiver could read them.
The receiver remains subscribed. Its internal cursor has been advanced
to the oldest message still retained by the channel; the next
successful try_recv call returns that message (unless further sends
overwrite it first).
The u64 is the number of messages that were skipped (dropped before
the receiver’s previous cursor position).
Trait Implementations§
Source§impl Clone for TryRecvError
impl Clone for TryRecvError
Source§fn clone(&self) -> TryRecvError
fn clone(&self) -> TryRecvError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TryRecvError
impl Debug for TryRecvError
Source§impl Display for TryRecvError
impl Display for TryRecvError
Source§impl Error for TryRecvError
impl Error for TryRecvError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for TryRecvError
impl PartialEq for TryRecvError
Source§fn eq(&self, other: &TryRecvError) -> bool
fn eq(&self, other: &TryRecvError) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for TryRecvError
impl StructuralPartialEq for TryRecvError
Auto Trait Implementations§
impl Freeze for TryRecvError
impl RefUnwindSafe for TryRecvError
impl Send for TryRecvError
impl Sync for TryRecvError
impl Unpin for TryRecvError
impl UnsafeUnpin for TryRecvError
impl UnwindSafe for TryRecvError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more