Trait futures_util::io::AsyncWriteExt [−][src]
pub trait AsyncWriteExt: AsyncWrite { fn flush<'a>(&'a mut self) -> Flush<'a, Self> { ... } fn close<'a>(&'a mut self) -> Close<'a, Self> { ... } fn write_all<'a>(&'a mut self, buf: &'a [u8]) -> WriteAll<'a, Self> { ... } }
An extension trait which adds utility methods to AsyncWrite
types.
Provided Methods
fn flush<'a>(&'a mut self) -> Flush<'a, Self>
Creates a future which will entirely flush this AsyncWrite
.
fn close<'a>(&'a mut self) -> Close<'a, Self>
Creates a future which will entirely close this AsyncWrite
.
fn write_all<'a>(&'a mut self, buf: &'a [u8]) -> WriteAll<'a, Self>
Write data into this object.
Creates a future that will write the entire contents of the buffer buf
into
this AsyncWrite
.
The returned future will not complete until all the data has been written.
Implementors
impl<W: AsyncWrite + ?Sized> AsyncWriteExt for W