[][src]Enum yenc::DecodeError

pub enum DecodeError {
    IncompleteData {
        expected_size: usize,
        actual_size: usize,
    },
    InvalidHeader {
        line: String,
        position: usize,
    },
    InvalidChecksum,
    IoError(Error),
}

Error enum for errors that can be encountered while decoding.

Variants

IncompleteData

Fewer or more bytes than expected.

Fields of IncompleteData

expected_size: usize

the expected size, as specified in the yenc header

actual_size: usize

the actual size, as found while reading

InvalidHeader

The header or footer line contains unexpected characters or is incomplete.

Fields of InvalidHeader

line: String

the header line

position: usize

the position in the line where the parsing error occurred

InvalidChecksum

CRC32 checksum of the part is not the expected checksum.

IoError(Error)

An I/O error occurred.

Trait Implementations

impl Debug for DecodeError[src]

impl Display for DecodeError[src]

impl From<Error> for DecodeError[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.