pub struct UdpClient { /* private fields */ }Implementations§
Source§impl UdpClient
impl UdpClient
pub fn new( tunnel_map: &Arc<RwLock<HashMap<SocketAddr, UnboundedSender<Vec<u8>>>>>, rx: UnboundedReceiver<Vec<u8>>, addr: SocketAddr, ) -> Self
pub async fn copy_bidirectional_udp( &mut self, listener: &Arc<UdpSocket>, sock: UdpSocket, ) -> Result<()>
pub async fn copy_bidirectional_tcp( &mut self, listener: &Arc<UdpSocket>, sock: TcpStream, ) -> Result<()>
Auto Trait Implementations§
impl Freeze for UdpClient
impl !RefUnwindSafe for UdpClient
impl Send for UdpClient
impl Sync for UdpClient
impl Unpin for UdpClient
impl !UnwindSafe for UdpClient
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