Enum swarm_discovery::IpClass
source · pub enum IpClass {
V4Only,
V6Only,
V4AndV6,
Auto,
}
Expand description
This selects which sockets will be created by the Discoverer.
Responses will be sent on that socket which received the query. Queries will prefer v4 when available. Default is IpClass::Auto, which means the socket will figure out what ip classes are available on its own.
Variants§
V4Only
Require the socket to bind to ipv4.
V6Only
Require the socket to bind to ipv6.
V4AndV6
Require the socket to bind to both ipv4 and ipv6.
Auto
Allow the socket to attempt to bind to both ipv4 and ipv6.
Only error if the socket is unable to bind to either.
Implementations§
Trait Implementations§
impl Copy for IpClass
impl Eq for IpClass
impl StructuralPartialEq for IpClass
Auto Trait Implementations§
impl Freeze for IpClass
impl RefUnwindSafe for IpClass
impl Send for IpClass
impl Sync for IpClass
impl Unpin for IpClass
impl UnwindSafe for IpClass
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> CloneToUninit for Twhere
T: Copy,
impl<T> CloneToUninit for Twhere
T: Copy,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)