Struct smoltcp::phy::TapInterface
[−]
[src]
pub struct TapInterface { /* fields omitted */ }
A virtual Ethernet interface.
Methods
impl TapInterface
[src]
fn new(name: &str) -> Result<TapInterface>
[src]
Attaches to a TAP interface called name
, or creates it if it does not exist.
If name
is a persistent interface configured with UID of the current user,
no special privileges are needed. Otherwise, this requires superuser privileges
or a corresponding capability set on the executable.
Trait Implementations
impl Debug for TapInterface
[src]
impl AsRawFd for TapInterface
[src]
impl Device for TapInterface
[src]
type RxBuffer = Vec<u8>
type TxBuffer = TxBuffer
fn limits(&self) -> DeviceLimits
[src]
Get a description of device limitations.
fn receive(&mut self, _timestamp: u64) -> Result<Self::RxBuffer>
[src]
Receive a frame. Read more
fn transmit(&mut self, _timestamp: u64, length: usize) -> Result<Self::TxBuffer>
[src]
Transmit a frame. Read more