pub trait RustStdioRuntime {
    // Required methods
    fn with_panic_output(&self, cb: IoWritePanicDynCallback<'_, ()>);
    fn with_stdin(
        &self,
        cb: IoReadDynCallback<'_, Result<usize, ReadError>>
    ) -> Result<usize, ReadError>;
    fn with_stdout(
        &self,
        cb: IoWriteDynCallback<'_, Result<usize, WriteError>>
    ) -> Result<usize, WriteError>;
    fn with_stderr(
        &self,
        cb: IoWriteDynCallback<'_, Result<usize, WriteError>>
    ) -> Result<usize, WriteError>;
}
Expand description

Runtime that implements stdio.

Required Methods§

source

fn with_panic_output(&self, cb: IoWritePanicDynCallback<'_, ()>)

Execute a closure with an implementer of IoWrite that can be used for panic output.

source

fn with_stdin( &self, cb: IoReadDynCallback<'_, Result<usize, ReadError>> ) -> Result<usize, ReadError>

Execute a closure with an implementer of IoRead that can be used for stdin.

source

fn with_stdout( &self, cb: IoWriteDynCallback<'_, Result<usize, WriteError>> ) -> Result<usize, WriteError>

Execute a closure with an implementer of IoWrite that can be used for stdout.

source

fn with_stderr( &self, cb: IoWriteDynCallback<'_, Result<usize, WriteError>> ) -> Result<usize, WriteError>

Execute a closure with an implementer of IoWrite that can be used for stderr.

Implementors§