Enum etherparse::ValueError[][src]

pub enum ValueError {
    Ipv4OptionsLengthBad(usize),
    Ipv4PayloadAndOptionsLengthTooLarge(usize),
    Ipv6PayloadLengthTooLarge(usize),
    UdpPayloadLengthTooLarge(usize),
    U8TooLarge {
        value: u8,
        max: u8,
        field: ErrorField,
    },
    U16TooLarge {
        value: u16,
        max: u16,
        field: ErrorField,
    },
    U32TooLarge {
        value: u32,
        max: u32,
        field: ErrorField,
    },
}

Errors in the given data

Variants

Error when the ipv4 options length is too big (cannot be bigger then 40 bytes and must be a multiple of 4 bytes).

Error when a given payload & ipv4 options block is bigger then what fits inside an ipv4 total_length field.

Error when a given payload & ipv6 header existsns block is bigger then what fits inside an ipv6 payload_length field.

Error when a given payload is bigger then what fits inside an udp packet Note that a the maximum payload size, as far as udp is conceirned, is max_value(u16) - 8. The 8 is for the size of the udp header itself.

Error when a u8 field in a header has a larger value then supported.

Fields of U8TooLarge

Error when a u16 field in a header has a larger value then supported.

Fields of U16TooLarge

Error when a u32 field in a header has a larger value then supported.

Fields of U32TooLarge

Trait Implementations

impl From<ValueError> for WriteError
[src]

Performs the conversion.

impl Debug for ValueError
[src]

Formats the value using the given formatter. Read more

impl PartialEq for ValueError
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Eq for ValueError
[src]

Auto Trait Implementations

impl Send for ValueError

impl Sync for ValueError