pub enum IgmpRepr {
MembershipQuery {
max_resp_time: Duration,
group_addr: Ipv4Address,
version: IgmpVersion,
},
MembershipReport {
group_addr: Ipv4Address,
version: IgmpVersion,
},
LeaveGroup {
group_addr: Ipv4Address,
},
}
Expand description
A high-level representation of an Internet Group Management Protocol v1/v2 header.
Variants§
Implementations§
source§impl Repr
impl Repr
sourcepub fn parse<T>(packet: &Packet<&T>) -> Result<Repr>where
T: AsRef<[u8]> + ?Sized,
pub fn parse<T>(packet: &Packet<&T>) -> Result<Repr>where
T: AsRef<[u8]> + ?Sized,
Parse an Internet Group Management Protocol v1/v2 packet and return a high-level representation.
sourcepub fn buffer_len(&self) -> usize
pub fn buffer_len(&self) -> usize
Return the length of a packet that will be emitted from this high-level representation.