Struct inet2_addr::InetSocketAddr
source · [−]Expand description
Internet socket address, which consists of InetAddr
IP or Tor address
and a port number (without protocol specification, i.e. TCP/UDP etc). If you
need to include transport-level protocol information into the socket
details, pls check InetSocketAddrExt
Fields
address: InetAddr
Address part of the socket
port: u16
Port of the socket
Implementations
Trait Implementations
sourceimpl Clone for InetSocketAddr
impl Clone for InetSocketAddr
sourcefn clone(&self) -> InetSocketAddr
fn clone(&self) -> InetSocketAddr
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for InetSocketAddr
impl Debug for InetSocketAddr
sourceimpl Default for InetSocketAddr
impl Default for InetSocketAddr
sourcefn default() -> InetSocketAddr
fn default() -> InetSocketAddr
Returns the “default value” for a type. Read more
sourceimpl Display for InetSocketAddr
impl Display for InetSocketAddr
sourceimpl From<InetSocketAddr> for SocketAddr
impl From<InetSocketAddr> for SocketAddr
sourcefn from(socket_addr: InetSocketAddr) -> Self
fn from(socket_addr: InetSocketAddr) -> Self
Converts to this type from the input type.
sourceimpl From<SocketAddr> for InetSocketAddr
impl From<SocketAddr> for InetSocketAddr
sourcefn from(addr: SocketAddr) -> Self
fn from(addr: SocketAddr) -> Self
Converts to this type from the input type.
sourceimpl From<SocketAddrV4> for InetSocketAddr
impl From<SocketAddrV4> for InetSocketAddr
sourcefn from(addr: SocketAddrV4) -> Self
fn from(addr: SocketAddrV4) -> Self
Converts to this type from the input type.
sourceimpl From<SocketAddrV6> for InetSocketAddr
impl From<SocketAddrV6> for InetSocketAddr
sourcefn from(addr: SocketAddrV6) -> Self
fn from(addr: SocketAddrV6) -> Self
Converts to this type from the input type.
sourceimpl FromStr for InetSocketAddr
impl FromStr for InetSocketAddr
sourceimpl Hash for InetSocketAddr
impl Hash for InetSocketAddr
sourceimpl Ord for InetSocketAddr
impl Ord for InetSocketAddr
sourceimpl PartialEq<InetSocketAddr> for InetSocketAddr
impl PartialEq<InetSocketAddr> for InetSocketAddr
sourcefn eq(&self, other: &InetSocketAddr) -> bool
fn eq(&self, other: &InetSocketAddr) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &InetSocketAddr) -> bool
fn ne(&self, other: &InetSocketAddr) -> bool
This method tests for !=
.
sourceimpl PartialOrd<InetSocketAddr> for InetSocketAddr
impl PartialOrd<InetSocketAddr> for InetSocketAddr
sourcefn partial_cmp(&self, other: &InetSocketAddr) -> Option<Ordering>
fn partial_cmp(&self, other: &InetSocketAddr) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
sourceimpl TryFrom<&'_ str> for InetSocketAddr
impl TryFrom<&'_ str> for InetSocketAddr
impl Copy for InetSocketAddr
impl Eq for InetSocketAddr
impl StructuralEq for InetSocketAddr
impl StructuralPartialEq for InetSocketAddr
Auto Trait Implementations
impl RefUnwindSafe for InetSocketAddr
impl Send for InetSocketAddr
impl Sync for InetSocketAddr
impl Unpin for InetSocketAddr
impl UnwindSafe for InetSocketAddr
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more