#[non_exhaustive]pub struct ReadError<B, S> {
pub kind: ReadErrorKind<B, S>,
pub cleanup: Vec<S>,
}Expand description
Why a request’s content was not read, with any failures to remove what was stored of its uploads.
Neither its Display nor its Debug output includes submitted content, filenames, or media types, so it is safe to log, although the body and store errors it holds are their own types’, with their own guarantees.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.kind: ReadErrorKind<B, S>What went wrong.
cleanup: Vec<S>The failures to remove what was stored of uploads, while cleaning up after kind. Empty when cleanup succeeded or nothing was stored.
Implementations§
Trait Implementations§
Source§impl<B: Error + 'static, S: Error + 'static> Error for ReadError<B, S>
The body or store error, for Body and Store. Cleanup failures are in ReadError::cleanup.
impl<B: Error + 'static, S: Error + 'static> Error for ReadError<B, S>
The body or store error, for Body and Store. Cleanup failures are in ReadError::cleanup.
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl<B, S> Forget for ReadError<B, S>
impl<B, S> Freeze for ReadError<B, S>
impl<B, S> RefUnwindSafe for ReadError<B, S>
impl<B, S> Send for ReadError<B, S>
impl<B, S> Sync for ReadError<B, S>
impl<B, S> Unpin for ReadError<B, S>
impl<B, S> UnsafeUnpin for ReadError<B, S>
impl<B, S> UnwindSafe for ReadError<B, S>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more