[−][src]Trait io::TryWrite
Associated Types
type Err
Provided methods
fn try_write(
&mut self,
buf: &[T]
) -> Result<Result<usize, EndOfFile>, Self::Err>
&mut self,
buf: &[T]
) -> Result<Result<usize, EndOfFile>, Self::Err>
w.try_write(buf) = w.try_writev(&[buf])
fn try_writev(
&mut self,
bufs: &[&[T]]
) -> Result<Result<usize, EndOfFile>, Self::Err>
&mut self,
bufs: &[&[T]]
) -> Result<Result<usize, EndOfFile>, Self::Err>
Push some data, at most bufs.fold(0, |n, buf| n+buf.len())
, to this sink from given buffers; return how many data were actually written, or a failure.
If no data can be written when called, return 0
rather than wait.