[][src]Enum phantom_relay::Destination

pub enum Destination {
    Host(Stringu16),
    Addr(SocketAddr),
}

Variants

Host(Stringu16)

Implementations

impl Destination[src]

pub fn from_host(host: &str, port: u16) -> Destination[src]

pub fn from_addr(addr: SocketAddr) -> Destination[src]

pub fn port(&self) -> u16[src]

pub fn unwrap_addr(&self) -> SocketAddr[src]

pub async fn connect<'_, '_, C: DnsHandle, P: ConnectionProvider<Conn = C>>(
    &'_ self,
    resolver: &'_ AsyncResolver<C, P>
) -> Result<TcpStream>
[src]

pub async fn resolve<'_, '_, C: DnsHandle, P: ConnectionProvider<Conn = C>>(
    &'_ self,
    resolver: &'_ AsyncResolver<C, P>
) -> Result<Vec<SocketAddr>>
[src]

Trait Implementations

impl Clone for Destination[src]

impl Debug for Destination[src]

impl Eq for Destination[src]

impl Hash for Destination[src]

impl PartialEq<Destination> for Destination[src]

impl StructuralEq for Destination[src]

impl StructuralPartialEq for Destination[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,