Enum fixed_width::DeserializeError [−][src]
pub enum DeserializeError {
Message(String),
Unsupported(String),
UnexpectedEndOfRecord,
InvalidUtf8(Utf8Error),
ParseBoolError(ParseBoolError),
ParseIntError(ParseIntError),
ParseFloatError(ParseFloatError),
}Errors that occur during deserialization.
Variants
Message(String)General error message as a String.
Unsupported(String)The desired type is unsupported by this deserializer.
UnexpectedEndOfRecordThe number of Fields given were less than the number of values to be deserialized.
InvalidUtf8(Utf8Error)The bytes given were not valid UTF-8.
ParseBoolError(ParseBoolError)A boolean value could not be parsed for this field.
ParseIntError(ParseIntError)An integer value could not be parsed for this field.
ParseFloatError(ParseFloatError)A float value could not be parsed for this field.
Trait Implementations
impl Debug for DeserializeError[src]
impl Debug for DeserializeErrorfn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl Error for DeserializeError[src]
impl Error for DeserializeErrorfn custom<T: Display>(msg: T) -> DeserializeError[src]
fn custom<T: Display>(msg: T) -> DeserializeErrorRaised when there is general error when deserializing a type. Read more
fn invalid_type(unexp: Unexpected, exp: &Expected) -> Self[src]
fn invalid_type(unexp: Unexpected, exp: &Expected) -> SelfRaised when a Deserialize receives a type different from what it was expecting. Read more
fn invalid_value(unexp: Unexpected, exp: &Expected) -> Self[src]
fn invalid_value(unexp: Unexpected, exp: &Expected) -> SelfRaised when a Deserialize receives a value of the right type but that is wrong for some other reason. Read more
fn invalid_length(len: usize, exp: &Expected) -> Self[src]
fn invalid_length(len: usize, exp: &Expected) -> SelfRaised when deserializing a sequence or map and the input data contains too many or too few elements. Read more
fn unknown_variant(variant: &str, expected: &'static [&'static str]) -> Self[src]
fn unknown_variant(variant: &str, expected: &'static [&'static str]) -> SelfRaised when a Deserialize enum type received a variant with an unrecognized name. Read more
fn unknown_field(field: &str, expected: &'static [&'static str]) -> Self[src]
fn unknown_field(field: &str, expected: &'static [&'static str]) -> SelfRaised when a Deserialize struct type received a field with an unrecognized name. Read more
fn missing_field(field: &'static str) -> Self[src]
fn missing_field(field: &'static str) -> SelfRaised when a Deserialize struct type expected to receive a required field with a particular name but that field was not present in the input. Read more
fn duplicate_field(field: &'static str) -> Self[src]
fn duplicate_field(field: &'static str) -> SelfRaised when a Deserialize struct type received more than one of the same field. Read more
impl StdError for DeserializeError[src]
impl StdError for DeserializeErrorfn description(&self) -> &str[src]
fn description(&self) -> &strThis method is soft-deprecated. Read more
fn cause(&self) -> Option<&StdError>[src]
fn cause(&self) -> Option<&StdError>The lower-level cause of this error, if any. Read more
impl Display for DeserializeError[src]
impl Display for DeserializeErrorfn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl From<Utf8Error> for DeserializeError[src]
impl From<Utf8Error> for DeserializeErrorimpl From<ParseBoolError> for DeserializeError[src]
impl From<ParseBoolError> for DeserializeErrorfn from(e: ParseBoolError) -> Self[src]
fn from(e: ParseBoolError) -> SelfPerforms the conversion.
impl From<ParseIntError> for DeserializeError[src]
impl From<ParseIntError> for DeserializeErrorfn from(e: ParseIntError) -> Self[src]
fn from(e: ParseIntError) -> SelfPerforms the conversion.
impl From<ParseFloatError> for DeserializeError[src]
impl From<ParseFloatError> for DeserializeErrorfn from(e: ParseFloatError) -> Self[src]
fn from(e: ParseFloatError) -> SelfPerforms the conversion.
impl From<DeserializeError> for Error[src]
impl From<DeserializeError> for Errorfn from(e: DeserializeError) -> Self[src]
fn from(e: DeserializeError) -> SelfPerforms the conversion.
Auto Trait Implementations
impl Send for DeserializeError
impl Send for DeserializeErrorimpl Sync for DeserializeError
impl Sync for DeserializeError