artichoke_backend::state::output

Trait Output

Source
pub trait Output:
    Send
    + Sync
    + Debug {
    // Required methods
    fn write_stdout<T: AsRef<[u8]>>(&mut self, bytes: T) -> Result<()>;
    fn write_stderr<T: AsRef<[u8]>>(&mut self, bytes: T) -> Result<()>;

    // Provided methods
    fn print<T: AsRef<[u8]>>(&mut self, bytes: T) -> Result<()> { ... }
    fn puts<T: AsRef<[u8]>>(&mut self, bytes: T) -> Result<()> { ... }
}

Required Methods§

Source

fn write_stdout<T: AsRef<[u8]>>(&mut self, bytes: T) -> Result<()>

Source

fn write_stderr<T: AsRef<[u8]>>(&mut self, bytes: T) -> Result<()>

Provided Methods§

Source

fn print<T: AsRef<[u8]>>(&mut self, bytes: T) -> Result<()>

Source

fn puts<T: AsRef<[u8]>>(&mut self, bytes: T) -> Result<()>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§