pub struct Ipv4Interface {
pub name: String,
pub index: u32,
pub mac: Option<[u8; 6]>,
pub addresses: Vec<Ipv4InterfaceAddr>,
pub is_loopback: bool,
pub is_up: bool,
pub is_running: bool,
pub is_multicast: bool,
pub is_broadcast: bool,
pub mtu: Option<u32>,
}Expand description
Information about an IPv4-capable interface.
Fields§
§name: StringInterface name (e.g., “eth0”, “en0”).
index: u32Interface index.
mac: Option<[u8; 6]>MAC address (if available).
addresses: Vec<Ipv4InterfaceAddr>IPv4 addresses on this interface.
is_loopback: boolWhether this is a loopback interface.
is_up: boolWhether the interface is up.
is_running: boolWhether the interface is running.
is_multicast: boolWhether multicast is enabled.
is_broadcast: boolWhether broadcast is supported.
mtu: Option<u32>Interface MTU.
Implementations§
Trait Implementations§
Source§impl Clone for Ipv4Interface
impl Clone for Ipv4Interface
Source§fn clone(&self) -> Ipv4Interface
fn clone(&self) -> Ipv4Interface
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for Ipv4Interface
impl RefUnwindSafe for Ipv4Interface
impl Send for Ipv4Interface
impl Sync for Ipv4Interface
impl Unpin for Ipv4Interface
impl UnsafeUnpin for Ipv4Interface
impl UnwindSafe for Ipv4Interface
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