pub trait Read {
// Required method
fn read(&mut self, _buf: &mut [u8]) -> Result<usize>;
// Provided method
fn read_exact(&mut self, buf: &mut [u8]) -> Result<()> { ... }
}
pub trait Read {
// Required method
fn read(&mut self, _buf: &mut [u8]) -> Result<usize>;
// Provided method
fn read_exact(&mut self, buf: &mut [u8]) -> Result<()> { ... }
}