pub enum TcpConnectError {
InsufficientCapacity,
Forbidden,
TimedOut,
Failure,
}Expand description
Errors that can be conveyed when allocating a socket for a client.
Variants§
InsufficientCapacity
The server does not have the capacity to handle this request.
Forbidden
Connection is forbidden by local policy.
TimedOut
Timed Out attempting to connect to the specified peer.
Failure
Faild for any other unspecified reason.
Implementations§
Source§impl TcpConnectError
impl TcpConnectError
Sourcepub fn into_error_code(self) -> u16
pub fn into_error_code(self) -> u16
Convert this error into an error code for the ErrorCode or AddressErrorCode attributes.
Trait Implementations§
Source§impl Clone for TcpConnectError
impl Clone for TcpConnectError
Source§fn clone(&self) -> TcpConnectError
fn clone(&self) -> TcpConnectError
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TcpConnectError
impl Debug for TcpConnectError
Source§impl Display for TcpConnectError
impl Display for TcpConnectError
Source§impl Error for TcpConnectError
impl Error for TcpConnectError
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()
Source§impl PartialEq for TcpConnectError
impl PartialEq for TcpConnectError
impl Copy for TcpConnectError
impl Eq for TcpConnectError
impl StructuralPartialEq for TcpConnectError
Auto Trait Implementations§
impl Freeze for TcpConnectError
impl RefUnwindSafe for TcpConnectError
impl Send for TcpConnectError
impl Sync for TcpConnectError
impl Unpin for TcpConnectError
impl UnsafeUnpin for TcpConnectError
impl UnwindSafe for TcpConnectError
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