pub trait Write {
// Required method
fn write(&mut self, buf: &[u8]) -> Result<(), Error>;
// Provided methods
fn write_all_blocking(&mut self, buf: &[u8]) -> Result<(), Error> { ... }
fn write_all<'life0, 'life1, 'async_trait>(
&'life0 mut self,
buf: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where 'life0: 'async_trait,
'life1: 'async_trait,
Self: Send + 'async_trait { ... }
}Required Methods§
Provided Methods§
fn write_all_blocking(&mut self, buf: &[u8]) -> Result<(), Error>
fn write_all<'life0, 'life1, 'async_trait>(
&'life0 mut self,
buf: &'life1 [u8],
) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
Self: Send + 'async_trait,
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".