pub trait IoWrite { type Error: Error; // Required method fn write(&mut self, buf: &[u8]) -> Result<(), Self::Error>; }
Minimal Write‑like trait used by encoders to avoid committing to a specific I/O model.
Write
Error type produced by the writer.
Write all bytes from buf.
buf
std