Struct ya_relay_stack::connection::ConnectionMeta
source · pub struct ConnectionMeta {
pub protocol: Protocol,
pub local: IpEndpoint,
pub remote: IpEndpoint,
}Fields§
§protocol: Protocol§local: IpEndpoint§remote: IpEndpointImplementations§
source§impl ConnectionMeta
impl ConnectionMeta
pub fn new(protocol: Protocol, local: IpEndpoint, remote: IpEndpoint) -> Self
pub fn unspecified(protocol: Protocol) -> Self
pub fn to_socket_addr(&self) -> SocketAddr
Trait Implementations§
source§impl Clone for ConnectionMeta
impl Clone for ConnectionMeta
source§fn clone(&self) -> ConnectionMeta
fn clone(&self) -> ConnectionMeta
Returns a copy 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 ConnectionMeta
impl Debug for ConnectionMeta
source§impl Display for ConnectionMeta
impl Display for ConnectionMeta
source§impl<'a> From<&'a ConnectionMeta> for SocketEndpoint
impl<'a> From<&'a ConnectionMeta> for SocketEndpoint
source§fn from(c: &'a ConnectionMeta) -> Self
fn from(c: &'a ConnectionMeta) -> Self
Converts to this type from the input type.
source§impl From<Connection> for ConnectionMeta
impl From<Connection> for ConnectionMeta
source§fn from(c: Connection) -> Self
fn from(c: Connection) -> Self
Converts to this type from the input type.
source§impl From<ConnectionMeta> for SocketDesc
impl From<ConnectionMeta> for SocketDesc
source§fn from(c: ConnectionMeta) -> Self
fn from(c: ConnectionMeta) -> Self
Converts to this type from the input type.
source§impl Hash for ConnectionMeta
impl Hash for ConnectionMeta
source§impl Ord for ConnectionMeta
impl Ord for ConnectionMeta
source§fn cmp(&self, other: &ConnectionMeta) -> Ordering
fn cmp(&self, other: &ConnectionMeta) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq<ConnectionMeta> for ConnectionMeta
impl PartialEq<ConnectionMeta> for ConnectionMeta
source§fn eq(&self, other: &ConnectionMeta) -> bool
fn eq(&self, other: &ConnectionMeta) -> bool
This method tests for
self and other values to be equal, and is used
by ==.source§impl PartialOrd<ConnectionMeta> for ConnectionMeta
impl PartialOrd<ConnectionMeta> for ConnectionMeta
source§fn partial_cmp(&self, other: &ConnectionMeta) -> Option<Ordering>
fn partial_cmp(&self, other: &ConnectionMeta) -> Option<Ordering>
1.0.0 · source§fn 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 moresource§impl TryFrom<SocketDesc> for ConnectionMeta
impl TryFrom<SocketDesc> for ConnectionMeta
impl Copy for ConnectionMeta
impl Eq for ConnectionMeta
impl StructuralEq for ConnectionMeta
impl StructuralPartialEq for ConnectionMeta
Auto Trait Implementations§
impl RefUnwindSafe for ConnectionMeta
impl Send for ConnectionMeta
impl Sync for ConnectionMeta
impl Unpin for ConnectionMeta
impl UnwindSafe for ConnectionMeta
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