pub trait ListenerProvider {
type Listener: StreamAccept + 'static;
// Required method
fn bind<A: ToSocketAddrs + Send>(
addr: A,
) -> impl Future<Output = Result<Self::Listener, Error>> + Send;
}Expand description
Provides an abstraction for bind
Required Associated Types§
Sourcetype Listener: StreamAccept + 'static
type Listener: StreamAccept + 'static
Listener obtained after bind
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.