Enum webrtc_util::vnet::net::Net
source · pub enum Net {
VNet(Arc<Mutex<VNet>>),
Ifs(Vec<Interface>),
}
Variants§
Implementations§
source§impl Net
impl Net
pub fn new(config: Option<NetConfig>) -> Self
pub async fn get_interfaces(&self) -> Vec<Interface>
pub async fn get_interface(&self, ifc_name: &str) -> Option<Interface>
pub fn is_virtual(&self) -> bool
pub async fn resolve_addr( &self, use_ipv4: bool, address: &str ) -> Result<SocketAddr>
pub async fn bind( &self, addr: SocketAddr ) -> Result<Arc<dyn Conn + Send + Sync>>
pub async fn dail( &self, use_ipv4: bool, remote_addr: &str ) -> Result<Arc<dyn Conn + Send + Sync>>
pub fn get_nic(&self) -> Result<Arc<Mutex<dyn Nic + Send + Sync>>>
Auto Trait Implementations§
impl Freeze for Net
impl !RefUnwindSafe for Net
impl Send for Net
impl Sync for Net
impl Unpin for Net
impl !UnwindSafe for Net
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