pub struct UnixSocketAddress(/* private fields */);Expand description
An address associated with a Unix socket.
This type is a thin wrapper around std::os::unix::net::SocketAddr. You
can convert to and from the standard library SocketAddr type using the
From trait. It is also just as easily convertabible to and from a tokio unix SocketAddr.
Implementations§
Source§impl UnixSocketAddress
impl UnixSocketAddress
Sourcepub fn is_unnamed(&self) -> bool
Available on target_family=unix only.
pub fn is_unnamed(&self) -> bool
target_family=unix only.Returns true if the address is unnamed.
Documentation reflected in SocketAddr
Sourcepub fn as_pathname(&self) -> Option<&Path>
Available on target_family=unix only.
pub fn as_pathname(&self) -> Option<&Path>
target_family=unix only.Returns the contents of this address if it is a pathname address.
Documentation reflected in SocketAddr
Trait Implementations§
Source§impl Clone for UnixSocketAddress
Available on target_family=unix only.
impl Clone for UnixSocketAddress
Available on
target_family=unix only.Source§fn clone(&self) -> UnixSocketAddress
fn clone(&self) -> UnixSocketAddress
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 UnixSocketAddress
Available on target_family=unix only.
impl Debug for UnixSocketAddress
Available on
target_family=unix only.Source§impl From<SocketAddr> for UnixSocketAddress
Available on target_family=unix only.
impl From<SocketAddr> for UnixSocketAddress
Available on
target_family=unix only.Source§fn from(value: SocketAddr) -> Self
fn from(value: SocketAddr) -> Self
Converts to this type from the input type.
Source§impl From<SocketAddr> for UnixSocketAddress
Available on target_family=unix only.
impl From<SocketAddr> for UnixSocketAddress
Available on
target_family=unix only.Source§fn from(value: TokioSocketAddress) -> Self
fn from(value: TokioSocketAddress) -> Self
Converts to this type from the input type.
Source§impl From<UnixSocketAddress> for SocketAddr
Available on target_family=unix only.
impl From<UnixSocketAddress> for SocketAddr
Available on
target_family=unix only.Source§fn from(value: UnixSocketAddress) -> Self
fn from(value: UnixSocketAddress) -> Self
Converts to this type from the input type.
Source§impl From<UnixSocketAddress> for TokioSocketAddress
Available on target_family=unix only.
impl From<UnixSocketAddress> for TokioSocketAddress
Available on
target_family=unix only.Source§fn from(value: UnixSocketAddress) -> Self
fn from(value: UnixSocketAddress) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for UnixSocketAddress
impl RefUnwindSafe for UnixSocketAddress
impl Send for UnixSocketAddress
impl Sync for UnixSocketAddress
impl Unpin for UnixSocketAddress
impl UnwindSafe for UnixSocketAddress
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§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more