pub trait Acceptor:
Clone
+ Sync
+ Send
+ Unpin
+ 'static {
type Stream<T: Stream>: Stream;
type Accept<T: Stream>: Future<Output = Result<Self::Stream<T>, Error>> + Unpin;
// Required method
fn accept<T: Stream>(&self, stream: T) -> Self::Accept<T>;
}
Required Associated Types§
type Stream<T: Stream>: Stream
type Accept<T: Stream>: Future<Output = Result<Self::Stream<T>, Error>> + Unpin
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.