Trait twizzler_runtime_api::IoWrite
source · pub trait IoWrite {
// Required methods
fn write(&self, buf: &[u8]) -> Result<usize, WriteError>;
fn flush(&self) -> Result<(), WriteError>;
}
Expand description
Trait for stdout/stderr
Required Methods§
sourcefn write(&self, buf: &[u8]) -> Result<usize, WriteError>
fn write(&self, buf: &[u8]) -> Result<usize, WriteError>
Write data from buf, returning the number of bytes written.
sourcefn flush(&self) -> Result<(), WriteError>
fn flush(&self) -> Result<(), WriteError>
Flush any buffered internal data. This function is allowed to be a no-op.