Enum mutnet::udp::ParseUdpError
source · pub enum ParseUdpError {
UnexpectedBufferEnd(UnexpectedBufferEndError),
InvalidChecksum(InvalidChecksumError),
LengthHeaderTooSmall {
length_header: usize,
},
}
Expand description
Error returned when parsing a UDP header.
Variants§
UnexpectedBufferEnd(UnexpectedBufferEndError)
The data buffer ended unexpectedly.
InvalidChecksum(InvalidChecksumError)
Invalid checksum.
LengthHeaderTooSmall
Length header value is smaller than the required eight bytes.
Trait Implementations§
source§impl Clone for ParseUdpError
impl Clone for ParseUdpError
source§fn clone(&self) -> ParseUdpError
fn clone(&self) -> ParseUdpError
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ParseUdpError
impl Debug for ParseUdpError
source§impl Display for ParseUdpError
impl Display for ParseUdpError
source§impl Error for ParseUdpError
impl Error for ParseUdpError
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. 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<InvalidChecksumError> for ParseUdpError
impl From<InvalidChecksumError> for ParseUdpError
source§fn from(value: InvalidChecksumError) -> Self
fn from(value: InvalidChecksumError) -> Self
Converts to this type from the input type.
source§impl From<ParseUdpError> for ParseNetworkDataError
impl From<ParseUdpError> for ParseNetworkDataError
source§fn from(value: ParseUdpError) -> Self
fn from(value: ParseUdpError) -> Self
Converts to this type from the input type.
source§impl From<UnexpectedBufferEndError> for ParseUdpError
impl From<UnexpectedBufferEndError> for ParseUdpError
source§fn from(value: UnexpectedBufferEndError) -> Self
fn from(value: UnexpectedBufferEndError) -> Self
Converts to this type from the input type.
source§impl Hash for ParseUdpError
impl Hash for ParseUdpError
source§impl Ord for ParseUdpError
impl Ord for ParseUdpError
source§fn cmp(&self, other: &ParseUdpError) -> Ordering
fn cmp(&self, other: &ParseUdpError) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for ParseUdpError
impl PartialEq for ParseUdpError
source§fn eq(&self, other: &ParseUdpError) -> bool
fn eq(&self, other: &ParseUdpError) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for ParseUdpError
impl PartialOrd for ParseUdpError
source§fn partial_cmp(&self, other: &ParseUdpError) -> Option<Ordering>
fn partial_cmp(&self, other: &ParseUdpError) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for ParseUdpError
impl Eq for ParseUdpError
impl StructuralPartialEq for ParseUdpError
Auto Trait Implementations§
impl Freeze for ParseUdpError
impl RefUnwindSafe for ParseUdpError
impl Send for ParseUdpError
impl Sync for ParseUdpError
impl Unpin for ParseUdpError
impl UnwindSafe for ParseUdpError
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