#[non_exhaustive]pub enum MailboxErrorKind {
Closed,
InvalidPort(PortId),
NoSenderForPort(PortId),
NoLocalSenderForPort(PortId),
PortClosed(PortId),
Send(PortId, Error),
Recv(PortId, Error),
Serialize(Error),
Deserialize(&'static str, Error),
Channel(ChannelError),
}
Expand description
The kinds of mailbox errors. This enum is marked non-exhaustive to allow for extensibility.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Closed
An operation was attempted on a closed mailbox.
InvalidPort(PortId)
The port associated with an operation was invalid.
NoSenderForPort(PortId)
There was no sender associated with the port.
NoLocalSenderForPort(PortId)
There was no local sender associated with the port. Returned by operations that require a local port.
PortClosed(PortId)
The port was closed.
Send(PortId, Error)
An error occured during a send operation.
Recv(PortId, Error)
An error occured during a receive operation.
Serialize(Error)
There was a serialization failure.
Deserialize(&'static str, Error)
There was a deserialization failure.
Channel(ChannelError)
There was an error during a channel operation.
Trait Implementations§
Source§impl Debug for MailboxErrorKind
impl Debug for MailboxErrorKind
Source§impl Display for MailboxErrorKind
impl Display for MailboxErrorKind
Source§impl Error for MailboxErrorKind
impl Error for MailboxErrorKind
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 From<ChannelError> for MailboxErrorKind
impl From<ChannelError> for MailboxErrorKind
Source§fn from(source: ChannelError) -> Self
fn from(source: ChannelError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for MailboxErrorKind
impl !RefUnwindSafe for MailboxErrorKind
impl Send for MailboxErrorKind
impl Sync for MailboxErrorKind
impl Unpin for MailboxErrorKind
impl !UnwindSafe for MailboxErrorKind
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
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<A, M> Handler<IndexedErasedUnbound<M>> for A
impl<A, M> Handler<IndexedErasedUnbound<M>> for A
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more