pub trait AsyncWrite {
type Error;
// Required methods
fn write<'a>(
&'a mut self,
buf: &'a [u8],
) -> impl Future<Output = Result<usize, Self::Error>>;
fn flush(&mut self) -> impl Future<Output = Result<(), Self::Error>>;
}Expand description
A stream that can be written to asynchronously.
Required Associated Types§
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".