pub struct Error { /* private fields */ }
Expand description
Represents errors that can occur handling HTTP streams.
Implementations
sourceimpl Error
impl Error
sourcepub fn is_canceled(&self) -> bool
pub fn is_canceled(&self) -> bool
Returns true if this was about a Request
that was canceled.
sourcepub fn is_connect(&self) -> bool
pub fn is_connect(&self) -> bool
Returns true if this was an error from Connect
.
sourcepub fn is_incomplete_message(&self) -> bool
pub fn is_incomplete_message(&self) -> bool
Returns true if the connection closed before a message could complete.
sourcepub fn is_body_write_aborted(&self) -> bool
pub fn is_body_write_aborted(&self) -> bool
Returns true if the body write was aborted.
Trait Implementations
sourceimpl Error for Error
impl Error for Error
sourcefn description(&self) -> &str
fn description(&self) -> &str
👎 Deprecated since 1.42.0:
use the Display impl or to_string()
sourcefn source(&self) -> Option<&(dyn StdError + 'static)>
fn source(&self) -> Option<&(dyn StdError + 'static)>
The lower-level source of this error, if any. Read more
Auto Trait Implementations
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl !UnwindSafe for Error
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more