Struct snap::IntoInnerError
source · [−]pub struct IntoInnerError<W> { /* private fields */ }
Expand description
IntoInnerError
occurs when consuming a Writer
fails.
Consuming the Writer
causes a flush to happen. If the flush fails, then
this error is returned, which contains both the original Writer
and
the error that occurred.
The type parameter W
is the unconsumed writer.
Implementations
sourceimpl<W> IntoInnerError<W>
impl<W> IntoInnerError<W>
sourcepub fn error(&self) -> &Error
pub fn error(&self) -> &Error
Returns the error which caused the call to into_inner
to fail.
This error was returned when attempting to flush the internal buffer.
sourcepub fn into_inner(self) -> W
pub fn into_inner(self) -> W
Returns the underlying writer which generated the error.
The returned value can be used for error recovery, such as re-inspecting the buffer.
Trait Implementations
sourceimpl<W> Debug for IntoInnerError<W>
impl<W> Debug for IntoInnerError<W>
sourceimpl<W> Display for IntoInnerError<W>
impl<W> Display for IntoInnerError<W>
sourceimpl<W: Any> Error for IntoInnerError<W>
impl<W: Any> Error for IntoInnerError<W>
sourcefn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
sourcefn cause(&self) -> Option<&dyn Error>
fn cause(&self) -> Option<&dyn Error>
👎Deprecated since 1.33.0: replaced by Error::source, which can support downcasting
Auto Trait Implementations
impl<W> !RefUnwindSafe for IntoInnerError<W>
impl<W> Send for IntoInnerError<W>where
W: Send,
impl<W> Sync for IntoInnerError<W>where
W: Sync,
impl<W> Unpin for IntoInnerError<W>where
W: Unpin,
impl<W> !UnwindSafe for IntoInnerError<W>
Blanket Implementations
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstablefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more