pub struct Library { /* private fields */ }Expand description
Instance of a opened wpcap library.
Implementations§
Trait Implementations§
Source§impl Library for Library
impl Library for Library
Source§fn default_paths() -> &'static [&'static str]where
Self: Sized,
fn default_paths() -> &'static [&'static str]where
Self: Sized,
Returns list of default paths to the library on the given platform.
Source§fn open_interface<'a>(
&'a self,
name: &str,
) -> Result<Box<dyn DynamicInterface<'a> + 'a>, Error>
fn open_interface<'a>( &'a self, name: &str, ) -> Result<Box<dyn DynamicInterface<'a> + 'a>, Error>
Opens interface (network card or network device) with the provided name. Read more
Source§fn version(&self) -> LibraryVersion
fn version(&self) -> LibraryVersion
Returns library version
Source§fn all_interfaces(&self) -> Result<Vec<InterfaceDescription>, Error>
fn all_interfaces(&self) -> Result<Vec<InterfaceDescription>, Error>
Obtains list of available network interfaces. Read more
fn open_interface_arc<'a>( &'a self, name: &str, ) -> Result<Arc<dyn DynamicInterface<'a> + 'a>, Error>
Source§fn open_default_paths() -> Result<Self, Error>where
Self: Sized,
fn open_default_paths() -> Result<Self, Error>where
Self: Sized,
Opens this library by searching for most common paths and names fro the given platform
Source§fn open_paths<'b, T>(paths: T) -> Result<Self, Error>
fn open_paths<'b, T>(paths: T) -> Result<Self, Error>
Opens library searching in the list of provided paths.
Auto Trait Implementations§
impl Freeze for Library
impl RefUnwindSafe for Library
impl Send for Library
impl Sync for Library
impl Unpin for Library
impl UnsafeUnpin for Library
impl UnwindSafe for Library
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