pub struct LinkInfo {
pub index: u32,
pub name: String,
pub mac: MacAddress,
pub mtu: u32,
pub flags: u32,
pub if_type: u16,
pub speed: u32,
}Expand description
Network interface information (serialized in NewLink responses)
Fields§
§index: u32Interface index
name: StringInterface name
mac: MacAddressMAC address
mtu: u32MTU
flags: u32Flags (IFF_UP, IFF_RUNNING, etc.)
if_type: u16Interface type (1=Ethernet, 801=Wi-Fi)
speed: u32Link speed in Mbps (0 if unknown)
Implementations§
Source§impl LinkInfo
impl LinkInfo
Sourcepub fn deserialize(buf: &[u8]) -> Result<Self, KernelError>
pub fn deserialize(buf: &[u8]) -> Result<Self, KernelError>
Deserialize from payload bytes
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LinkInfo
impl RefUnwindSafe for LinkInfo
impl Send for LinkInfo
impl Sync for LinkInfo
impl Unpin for LinkInfo
impl UnwindSafe for LinkInfo
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)