Skip to main content

QuicPeekRouter

Trait QuicPeekRouter 

pub trait QuicPeekRouter<O>:
    Send
    + Sync
    + 'static {
    type Route: QuicPeekRoute<O>;

    // Required method
    fn route<Socket>(
        &self,
        socket: &Socket,
        metadata: &DatagramMetadata,
        data: &[u8],
    ) -> Result<Option<Self::Route>, Box<dyn Error + Send + Sync>>
       where Socket: DatagramSocket;
}
Available on crate features quic and std only.
Expand description

Optional first-datagram routing, sharing inspection’s deadline and receive buffer. A positive decision is terminal: subsequent rejection must never invoke fallback policy.

Required Associated Types§

Required Methods§

fn route<Socket>( &self, socket: &Socket, metadata: &DatagramMetadata, data: &[u8], ) -> Result<Option<Self::Route>, Box<dyn Error + Send + Sync>>
where Socket: DatagramSocket,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§