pub trait Endpoint: 'static + Send {
    type PathHandle: Handle;
    type Subscriber: Subscriber;

    const ENDPOINT_TYPE: Type;

    fn receive<Rx, C>(&mut self, rx: &mut Rx, clock: &C)
    where
        Rx: Queue<Handle = Self::PathHandle>,
        C: Clock
;
fn transmit<Tx, C>(&mut self, tx: &mut Tx, clock: &C)
    where
        Tx: Queue<Handle = Self::PathHandle>,
        C: Clock
;
fn poll_wakeups<C>(
        &mut self,
        cx: &mut Context<'_>,
        clock: &C
    ) -> Poll<Result<usize, CloseError>>
    where
        C: Clock
;
fn timeout(&self) -> Option<Timestamp>;
fn set_max_mtu(&mut self, max_mtu: MaxMtu);
fn subscriber(&mut self) -> &mut Self::Subscriber; fn wakeups<C>(&'a mut self, clock: &'a C) -> Wakeups<'a, Self, C>Notable traits for Wakeups<'a, E, C>impl<'a, E, C> Future for Wakeups<'a, E, C> where
    E: Endpoint,
    C: Clock
type Output = Result<usize, CloseError>;

    where
        C: Clock
, { ... } }
Expand description

The main interface for a QUIC endpoint

Associated Types

Associated Constants

Required methods

Receives and processes datagrams for the Rx queue

Transmits outgoing datagrams into the Tx queue

Polls for any application-space wakeups

When successful, the number of wakeups is returned.

Returns the latest Timestamp at which transmit should be called

Sets the largest maximum transmission unit (MTU) that can be sent on a path

Returns the endpoint’s event subscriber

Provided methods

Returns a future which polls for application-space wakeups

When successful, the number of wakeups is returned.

Implementors