pub struct TransportInfo {
pub src_port: Option<u16>,
pub dst_port: Option<u16>,
pub protocol: Protocol,
pub icmp_type: Option<IcmpType>,
pub igmp_type: Option<IgmpType>,
}Expand description
Info extracted from the transport layer header.
Fields§
§src_port: Option<u16>Source port, if the packet is a TCP or UDP packet.
dst_port: Option<u16>Destination port, if the packet is a TCP or UDP packet.
protocol: ProtocolProtocol carried by the packet.
icmp_type: Option<IcmpType>ICMP message type, if the packet is an ICMP packet.
igmp_type: Option<IgmpType>IGMP message type, if the packet is an IGMP packet.
Trait Implementations§
Source§impl Clone for TransportInfo
impl Clone for TransportInfo
Source§fn clone(&self) -> TransportInfo
fn clone(&self) -> TransportInfo
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for TransportInfo
Source§impl Debug for TransportInfo
impl Debug for TransportInfo
impl Eq for TransportInfo
Source§impl Hash for TransportInfo
impl Hash for TransportInfo
Source§impl PartialEq for TransportInfo
impl PartialEq for TransportInfo
impl StructuralPartialEq for TransportInfo
Auto Trait Implementations§
impl Freeze for TransportInfo
impl RefUnwindSafe for TransportInfo
impl Send for TransportInfo
impl Sync for TransportInfo
impl Unpin for TransportInfo
impl UnsafeUnpin for TransportInfo
impl UnwindSafe for TransportInfo
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