[−][src]Struct wireguard_tools_rs::Device
Methods
impl Device
[src]
pub fn name(&self) -> Result<String>
[src]
pub fn set_name<S: Into<CString>>(&mut self, name: S) -> Result<()>
[src]
pub fn public_key(&self) -> Option<PublicKey>
[src]
pub fn secret_key(&self) -> Option<SecretKey>
[src]
pub fn set_secret_key(&mut self, secret_key: Option<SecretKey>)
[src]
pub fn listen_port(&self) -> Option<u16>
[src]
pub fn set_listen_port(&mut self, listen_port: Option<u16>)
[src]
pub fn fwmark(&self) -> Option<u32>
[src]
pub fn set_fwmark(&mut self, fwmark: Option<u32>)
[src]
pub fn ifindex(&self) -> u32
[src]
pub fn set_ifindex(&mut self, ifindex: u32)
[src]
pub fn devices() -> Result<Vec<Device>>
[src]
pub fn get<S: Into<Vec<u8>>>(device_name: S) -> Result<Device>
[src]
pub fn apply(&self) -> Result<()>
[src]
pub fn add<S: Into<Vec<u8>>>(device_name: S) -> Result<()>
[src]
pub fn del(&self) -> Result<()>
[src]
pub fn get_peer<'a>(&'a self, peer: &PublicKey) -> Option<Peer<'a>>
[src]
pub fn peers<'a>(&'a self) -> Vec<Peer<'a>>
[src]
pub fn next_handshake(&self) -> Option<Duration>
[src]
Trait Implementations
impl Debug for Device
[src]
impl Drop for Device
[src]
impl Send for Device
[src]
impl Sync for Device
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,