#[non_exhaustive]pub enum Error {
Transport(String),
Io(String),
Codec(String),
Closed,
Auth(String),
Unsupported(&'static str),
}Expand description
The error type returned by all fallible pamoja operations.
This enum is #[non_exhaustive]: new variants may be added in future releases
without a breaking change, so downstream match expressions must include a
wildcard arm.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Transport(String)
A transport-level failure while connecting, sending, or receiving.
The payload is a human-readable description provided by the transport.
Io(String)
A device or peripheral input/output operation failed.
The payload is a human-readable description of the I/O fault.
Codec(String)
A payload could not be encoded or decoded.
The payload describes the encoding or decoding fault.
Closed
The operation targeted a resource that is closed or disconnected.
Auth(String)
A security check failed, such as an invalid identity or a bad signature.
The payload describes the authentication or integrity fault.
Unsupported(&'static str)
The requested capability is not compiled into this build.
The payload names the missing capability, for example "mqtt".
Trait Implementations§
Source§impl Error for Error
Available on crate feature std only.
impl Error for Error
std only.1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()