pub trait UdpProvider {
    type UdpSocket: UdpSocket + Send + Sync + Unpin + 'static;
    fn bind<'life0, 'life1, 'async_trait>(
        &'life0 self,
        addr: &'life1 SocketAddr
    ) -> Pin<Box<dyn Future<Output = IoResult<Self::UdpSocket>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        'life1: 'async_trait,
        Self: 'async_trait
; }
Expand description

Trait for a runtime that can send and receive UDP datagrams.

Associated Types

The type of Udp Socket returned by Self::bind()

Required methods

Bind a local port to send and receive packets from

Implementors