pub enum BufReadError {
Show 13 variants
InvalidVarInt,
InvalidVarLong,
CouldNotReadBytes,
StringLengthTooLong {
length: u32,
max_length: u32,
},
Io {
source: Error,
},
InvalidUtf8 {
bytes: Vec<u8>,
lossy: String,
},
UnexpectedEnumVariant {
id: i32,
},
UnexpectedStringEnumVariant {
id: String,
},
UnexpectedEof {
attempted_read: usize,
actual_read: usize,
backtrace: Backtrace,
},
Custom(String),
Deserialization {
source: Error,
},
Nbt {
source: Error,
},
DeserializeNbt {
source: DeserializeError,
},
}
Variants§
InvalidVarInt
InvalidVarLong
CouldNotReadBytes
StringLengthTooLong
Io
InvalidUtf8
UnexpectedEnumVariant
UnexpectedStringEnumVariant
UnexpectedEof
Custom(String)
Deserialization
Nbt
Fields
§
source: Error
DeserializeNbt
Fields
§
source: DeserializeError
Trait Implementations§
Source§impl Debug for BufReadError
impl Debug for BufReadError
Source§impl Display for BufReadError
impl Display for BufReadError
Source§impl Error for BufReadError
impl Error for BufReadError
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
Source§fn provide<'_request>(&'_request self, request: &mut Request<'_request>)
fn provide<'_request>(&'_request self, request: &mut Request<'_request>)
🔬This is a nightly-only experimental API. (
error_generic_member_access
)Provides type-based access to context intended for error reports. 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()
Source§impl From<DeserializeError> for BufReadError
impl From<DeserializeError> for BufReadError
Source§impl From<Error> for BufReadError
impl From<Error> for BufReadError
Source§impl From<Error> for BufReadError
impl From<Error> for BufReadError
Auto Trait Implementations§
impl !Freeze for BufReadError
impl !RefUnwindSafe for BufReadError
impl Send for BufReadError
impl Sync for BufReadError
impl Unpin for BufReadError
impl !UnwindSafe for BufReadError
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