pub struct RequestFailure { /* private fields */ }Expand description
A request error with optional structured connection-failure detail.
The ordinary Error remains the compatibility surface. Use
Client::send_detailed or
RequestBuilder::send_detailed
when native Rust code needs the additional, evidence-backed network
classification.
Implementations§
Source§impl RequestFailure
impl RequestFailure
Sourcepub fn into_error(self) -> Error
pub fn into_error(self) -> Error
Consume the detailed wrapper and return the original public error.
Sourcepub fn network_failure_kind(&self) -> Option<NetworkFailureKind>
pub fn network_failure_kind(&self) -> Option<NetworkFailureKind>
Return evidence-backed connection-failure detail, when available.
Sourcepub fn is_timeout(&self) -> bool
pub fn is_timeout(&self) -> bool
Return whether the error represents a timeout.
This includes both ordinary request-phase Error::Timeout values
and established-transport inactivity Error::TransportIoTimeout
values. Caller-dialer timeout categories remain available through
Error::custom_transport_error and are not reclassified here.
Sourcepub fn timeout_phase(&self) -> Option<TimeoutPhase>
pub fn timeout_phase(&self) -> Option<TimeoutPhase>
Return the request timeout phase, when the error carries one.
Established-transport inactivity timeouts intentionally return
None; they are not ordinary request-phase timeouts.
Trait Implementations§
Source§impl Debug for RequestFailure
impl Debug for RequestFailure
Source§impl Display for RequestFailure
impl Display for RequestFailure
Source§impl Error for RequestFailure
impl Error for RequestFailure
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()