pub struct MQDevice(/* private fields */);
Expand description
Implementations§
Methods from Deref<Target = Device>§
Sourcepub fn bring_up(&self) -> Result<()>
pub fn bring_up(&self) -> Result<()>
Brings the device up which makes it ready to send and receive packets.
Sourcepub fn bring_down(&self) -> Result<()>
pub fn bring_down(&self) -> Result<()>
Brings the device down which makes it unable to send and receive packets.
Sourcepub fn set_netmask(&self, netmask: Ipv4Addr) -> Result<()>
pub fn set_netmask(&self, netmask: Ipv4Addr) -> Result<()>
Sets the netmask of the device.
Sourcepub fn get_netmask(&self) -> Result<Ipv4Addr>
pub fn get_netmask(&self) -> Result<Ipv4Addr>
Sets the netmask of the device.
Sourcepub fn set_ipv6_addr(&self, addr: Ipv6Addr) -> Result<()>
pub fn set_ipv6_addr(&self, addr: Ipv6Addr) -> Result<()>
Adds the specified addr
to the list of IPv6 addresses of the interface.
Sourcepub fn get_ipv6_addrs(&self) -> Result<Vec<Ipv6Addr>>
pub fn get_ipv6_addrs(&self) -> Result<Vec<Ipv6Addr>>
Returns the list of IPv6 addresses of the interface.
Sourcepub fn del_ipv6_addr(&self, addr: Ipv6Addr) -> Result<()>
pub fn del_ipv6_addr(&self, addr: Ipv6Addr) -> Result<()>
Deletes the specified IPv6 address from the interface.
Sourcepub fn set_brd_addr(&self, addr: Ipv4Addr) -> Result<()>
pub fn set_brd_addr(&self, addr: Ipv4Addr) -> Result<()>
Sets the broadcast IPv4 address of the device.
Sourcepub fn get_brd_addr(&self) -> Result<Ipv4Addr>
pub fn get_brd_addr(&self) -> Result<Ipv4Addr>
Returns the broadcast IPv4 address of the device.
Sourcepub fn set_dst_addr(&self, addr: Ipv4Addr) -> Result<()>
pub fn set_dst_addr(&self, addr: Ipv4Addr) -> Result<()>
Sets the destination IPv4 address of the device.
Sourcepub fn get_dst_addr(&self) -> Result<Ipv4Addr>
pub fn get_dst_addr(&self) -> Result<Ipv4Addr>
Returns the destination IPv4 address of the device.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for MQDevice
impl RefUnwindSafe for MQDevice
impl Send for MQDevice
impl Sync for MQDevice
impl Unpin for MQDevice
impl UnwindSafe for MQDevice
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