pub struct EtherType(/* private fields */);Expand description
Ethernet protocol type values. A semantic Ethernet protocol type field.
The two-octet type field follows the destination and source addresses in the Ethernet encapsulation described by RFC 894.
Implementations§
Source§impl EtherType
impl EtherType
Sourcepub const IPV4: Self
pub const IPV4: Self
The Internet Protocol version 4 EtherType (0x0800).
RFC 894 specifies this value for IP datagrams on Ethernet; it is also listed in the IANA IEEE 802 Numbers registry.
Sourcepub const ARP: Self
pub const ARP: Self
The Address Resolution Protocol EtherType (0x0806).
RFC 826 names 0x0806 as the Ethernet protocol type for ARP; it is also listed
in the IANA IEEE 802 Numbers registry.
Sourcepub const IPV6: Self
pub const IPV6: Self
The Internet Protocol version 6 EtherType (0x86dd).
RFC 2464 section 3 specifies this value for IPv6 packets encapsulated in Ethernet; it is also listed in the IANA IEEE 802 Numbers registry.
Trait Implementations§
impl Copy for EtherType
impl Eq for EtherType
impl StructuralPartialEq for EtherType
Auto Trait Implementations§
impl Freeze for EtherType
impl RefUnwindSafe for EtherType
impl Send for EtherType
impl Sync for EtherType
impl Unpin for EtherType
impl UnsafeUnpin for EtherType
impl UnwindSafe for EtherType
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