pub enum Error {
Io(Error),
Serialize(String),
Deserialize(String),
Protocol(String),
Auth(String),
ConnectionClosed,
Cancelled,
UnsupportedCapability,
}Expand description
An error from session establishment, transport, or an individual call.
Variants§
Io(Error)
The underlying transport failed.
Serialize(String)
Serializing an outgoing request or response failed.
Deserialize(String)
Deserializing an incoming request or response failed.
Protocol(String)
The peer sent data that violates the RPC protocol.
Auth(String)
A pre-shared key was rejected, missing, or unexpected.
Covers both a locally supplied key that cannot be used (see
AuthKey::new) and a peer that failed the check during negotiation.
The message never includes key material.
ConnectionClosed
The local or peer session closed before the operation completed.
Cancelled
The peer cancelled this call before it received a response.
UnsupportedCapability
A requested transport capability is unavailable.
Returned when an OsHandle is serialized
over a session whose transport cannot carry handle attachments (a
generic byte-stream transport rather than a Unix-domain socket or a
Windows named pipe).
Trait Implementations§
Source§impl Error for Error
impl Error for Error
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()