[][src]Struct async_tun::Params

pub struct Params {
    pub name: Option<String>,
    pub flags: i16,
}

Represents parameters for creating a new Tun/Tap device on Linux.

Fields

name: Option<String>flags: i16

Implementations

impl Params[src]

pub fn new(name: &str, kind: Kind, packet_info: bool) -> Self[src]

Creates a new instance of Params. name is the name of device (max length: 16 characters), if it is empty, then device name is set by kernel. kind specifies the type of device (Tun or Tap). if packet_info is false, then IFF_NO_PI is set.

Auto Trait Implementations

impl RefUnwindSafe for Params

impl Send for Params

impl Sync for Params

impl Unpin for Params

impl UnwindSafe for Params

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.