Struct xenet_packet::ipv4::Ipv4
source · pub struct Ipv4 {Show 15 fields
pub version: u4,
pub header_length: u4,
pub dscp: u6,
pub ecn: u2,
pub total_length: u16be,
pub identification: u16be,
pub flags: u3,
pub fragment_offset: u13be,
pub ttl: u8,
pub next_level_protocol: IpNextLevelProtocol,
pub checksum: u16be,
pub source: Ipv4Addr,
pub destination: Ipv4Addr,
pub options: Vec<Ipv4Option>,
pub payload: Vec<u8>,
}
Expand description
Represents an IPv4 Packet.
Fields§
§version: u4
§header_length: u4
§dscp: u6
§ecn: u2
§total_length: u16be
§identification: u16be
§flags: u3
§fragment_offset: u13be
§ttl: u8
§next_level_protocol: IpNextLevelProtocol
§checksum: u16be
§source: Ipv4Addr
§destination: Ipv4Addr
§options: Vec<Ipv4Option>
§payload: Vec<u8>
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Ipv4
impl Send for Ipv4
impl Sync for Ipv4
impl Unpin for Ipv4
impl UnwindSafe for Ipv4
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