pub struct Interfaces { /* private fields */ }
Expand description
A list of the network interfaces available on this system. Obtained from if_nameindex()
.
Implementations§
Source§impl Interfaces
impl Interfaces
Sourcepub fn iter(&self) -> InterfacesIter<'_> ⓘ
pub fn iter(&self) -> InterfacesIter<'_> ⓘ
Iterate over the interfaces in this list.
Sourcepub fn to_slice(&self) -> &[Interface]
pub fn to_slice(&self) -> &[Interface]
Convert this to a slice of interfaces. Note that the underlying interfaces list is
null-terminated, so calling this calculates the length. If random access isn’t needed,
Interfaces::iter()
should be used instead.
Trait Implementations§
Source§impl Debug for Interfaces
impl Debug for Interfaces
Source§impl Drop for Interfaces
impl Drop for Interfaces
Auto Trait Implementations§
impl Freeze for Interfaces
impl RefUnwindSafe for Interfaces
impl !Send for Interfaces
impl !Sync for Interfaces
impl Unpin for Interfaces
impl UnwindSafe for Interfaces
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