Struct smoltcp::wire::IgmpPacket

source ·
pub struct IgmpPacket<T: AsRef<[u8]>> { /* private fields */ }
Expand description

A read/write wrapper around an Internet Group Management Protocol v1/v2 packet buffer.

Implementations§

Internet Group Management Protocol v1/v2 defined in RFC 2236.

Imbue a raw octet buffer with IGMPv2 packet structure.

Shorthand for a combination of new_unchecked and check_len.

Ensure that no accessor method will panic if called. Returns Err(Error::Truncated) if the buffer is too short.

Consume the packet, returning the underlying buffer.

Return the message type field.

Return the maximum response time, using the encoding specified in RFC 3376: 4.1.1. Max Resp Code.

Return the checksum field.

Return the source address field.

Validate the header checksum.

Fuzzing

This function always returns true when fuzzing.

Set the message type field.

Set the maximum response time, using the encoding specified in [RFC 3376]: 4.1.1. Max Resp Code.

Set the checksum field.

Set the group address field

Compute and fill in the header checksum.

Trait Implementations§

Formats the value using the given formatter. Read more
Formats the value using the given formatter. Read more
Write a concise, formatted representation of a packet contained in the provided buffer, and any nested packets it may contain. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Converts the given value to a String. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.