Struct socks5_server::connection::associate::AssociateUdpSocket
source · [−]pub struct AssociateUdpSocket(_);Implementations
sourceimpl AssociateUdpSocket
impl AssociateUdpSocket
pub async fn connect<A: ToSocketAddrs>(&self, addr: A) -> Result<()>
pub fn local_addr(&self) -> Result<SocketAddr>
pub fn peer_addr(&self) -> Result<SocketAddr>
pub async fn recv(&self) -> Result<(Bytes, u8, Address)>
pub async fn recv_from(&self) -> Result<(Bytes, u8, Address, SocketAddr)>
pub async fn send<P: AsRef<[u8]>>(
&self,
pkt: P,
frag: u8,
from_addr: Address
) -> Result<usize>
pub async fn send_to<P: AsRef<[u8]>>(
&self,
pkt: P,
frag: u8,
from_addr: Address,
to_addr: SocketAddr
) -> Result<usize>
Trait Implementations
sourceimpl Debug for AssociateUdpSocket
impl Debug for AssociateUdpSocket
sourceimpl From<AssociateUdpSocket> for UdpSocket
impl From<AssociateUdpSocket> for UdpSocket
sourcefn from(associate: AssociateUdpSocket) -> Self
fn from(associate: AssociateUdpSocket) -> Self
Converts to this type from the input type.
Auto Trait Implementations
impl RefUnwindSafe for AssociateUdpSocket
impl Send for AssociateUdpSocket
impl Sync for AssociateUdpSocket
impl Unpin for AssociateUdpSocket
impl UnwindSafe for AssociateUdpSocket
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