pub trait Write {
// Required methods
fn write(&mut self, buf: &[u8]) -> Result<usize>;
fn flush(&mut self) -> Result<()>;
// Provided method
fn write_all(&mut self, buf: &[u8]) -> Result<()> { ... }
}Expand description
no_std-compatible read/write traits used by streaming APIs.
no_std-compatible write trait used by streaming interfaces.
This trait mirrors the core behavior of std::io::Write.