pub enum BindError {
InvalidState,
InUse,
NoFreePorts,
Unaddressable,
}Expand description
Error returned by UdpSocket::bind.
Variants§
InvalidState
The socket is already bound.
InUse
Another UDP socket holds an identical 4-tuple.
NoFreePorts
No free port in the ephemeral range (only possible with tens of thousands of bound sockets).
Unaddressable
The local and remote addresses belong to different address families, or no local address is available for the given remote.
Trait Implementations§
impl Copy for BindError
impl Eq for BindError
Source§impl Error for BindError
impl Error for BindError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
impl StructuralPartialEq for BindError
Auto Trait Implementations§
impl Freeze for BindError
impl RefUnwindSafe for BindError
impl Send for BindError
impl Sync for BindError
impl Unpin for BindError
impl UnsafeUnpin for BindError
impl UnwindSafe for BindError
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