pub struct NetDevice { /* private fields */ }
Expand description
A reference to the network device
Implementations§
Source§impl NetDevice
impl NetDevice
Sourcepub fn open(adapter: u32, device: u32) -> Result<NetDevice>
pub fn open(adapter: u32, device: u32) -> Result<NetDevice>
Attempts to open a network device in read-write mode
Sourcepub fn add_if(&self, pid: u16, feedtype: u8) -> Result<NetInterface<'_>>
pub fn add_if(&self, pid: u16, feedtype: u8) -> Result<NetInterface<'_>>
Creates a new network interface and returns interface number
Sourcepub fn remove_if(&self, interface: NetInterface<'_>) -> Result<()>
pub fn remove_if(&self, interface: NetInterface<'_>) -> Result<()>
Removes a network interface
Trait Implementations§
Auto Trait Implementations§
impl Freeze for NetDevice
impl RefUnwindSafe for NetDevice
impl Send for NetDevice
impl Sync for NetDevice
impl Unpin for NetDevice
impl UnwindSafe for NetDevice
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