Struct pnet_datalink::NetworkInterface [−][src]
Represents a network interface and its associated addresses.
Fields
name: String
The name of the interface.
index: u32
The interface index (operating system specific).
mac: Option<MacAddr>
A MAC address for the interface.
ips: Vec<IpNetwork>
IP addresses and netmasks for the interface.
flags: u32
Operating system specific flags for the interface.
Implementations
impl NetworkInterface
[src][−]
pub fn mac_address(&self) -> MacAddr
[src][−]
Retrieve the MAC address associated with the interface.
pub fn is_up(&self) -> bool
[src]
pub fn is_broadcast(&self) -> bool
[src]
pub fn is_loopback(&self) -> bool
[src][−]
Is the interface a loopback interface?
pub fn is_point_to_point(&self) -> bool
[src]
pub fn is_multicast(&self) -> bool
[src]
Trait Implementations
impl Clone for NetworkInterface
[src][+]
impl Debug for NetworkInterface
[src][+]
impl Display for NetworkInterface
[src][+]
impl Eq for NetworkInterface
[src]
impl Hash for NetworkInterface
[src][+]
impl PartialEq<NetworkInterface> for NetworkInterface
[src][+]
impl StructuralEq for NetworkInterface
[src]
impl StructuralPartialEq for NetworkInterface
[src]
Auto Trait Implementations
impl RefUnwindSafe for NetworkInterface
impl Send for NetworkInterface
impl Sync for NetworkInterface
impl Unpin for NetworkInterface
impl UnwindSafe for NetworkInterface
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src][+]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src][+]
T: ?Sized,
impl<T> From<T> for T
[src][+]
impl<T, U> Into<U> for T where
U: From<T>,
[src][+]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src][+]
T: Clone,
impl<T> ToString for T where
T: Display + ?Sized,
[src][+]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src][+]
U: Into<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src][+]
U: TryFrom<T>,