pub trait UdpBindingsTypes: Sized + 'static {
    type ExternalData<I: Ip>: Debug + Send + Sync + 'static;
Expand description

The bindings context providing external types to UDP sockets.


We’d like this trait to take an I type parameter instead of using GAT to get the IP version, however we end up with problems due to the shape of [DatagramSocketSpec] and the underlying support for dual stack sockets.

This is completely fine for all known implementations, except for a rough edge in fake tests bindings contexts that are already parameterized on I themselves. This is still better than relying on Box<dyn Any> to keep the external data in our references so we take the rough edge.

Required Associated Types§


type ExternalData<I: Ip>: Debug + Send + Sync + 'static

Opaque bindings data held by core for a given IP version.

Object Safety§

This trait is not object safe.