Enum bincode::internal::ErrorKind
[−]
[src]
pub enum ErrorKind { IoError(IoError), InvalidEncoding { desc: &'static str, detail: Option<String>, }, SizeLimit, SequenceMustHaveLength, Custom(String), }
The kind of error that can be produced during a serialization or deserialization.
Variants
IoError(IoError)
If the error stems from the reader/writer that is being used during (de)serialization, that error will be stored and returned here.
InvalidEncoding
If the bytes in the reader are not decodable because of an invalid
encoding, this error will be returned. This error is only possible
if a stream is corrupted. A stream produced from encode
or encode_into
should never produce an InvalidEncoding error.
Fields of InvalidEncoding
desc: &'static str | |
detail: Option<String> |
SizeLimit
If (de)serializing a message takes more than the provided size limit, this error is returned.
SequenceMustHaveLength
Bincode can not encode sequences of unknown length (like iterators).
Custom(String)
A custom error message from Serde.
Trait Implementations
impl Debug for ErrorKind
[src]
impl Error for ErrorKind
[src]
fn description(&self) -> &str
A short description of the error. Read more
fn cause(&self) -> Option<&Error>
The lower-level cause of this error, if any. Read more