Trait ockam_command::TerminalWriter
source · pub trait TerminalWriter: Clone {
// Required methods
fn stdout(no_color: bool) -> Self;
fn stderr(no_color: bool) -> Self;
fn is_tty(&self) -> bool;
fn write(&mut self, s: impl AsRef<str>) -> Result<()>;
fn rewrite(&mut self, s: impl AsRef<str>) -> Result<()>;
fn write_line(&self, s: impl AsRef<str>) -> Result<()>;
}
Expand description
Trait defining the main methods to write messages to a terminal stream.
Required Methods§
fn stdout(no_color: bool) -> Self
fn stderr(no_color: bool) -> Self
fn is_tty(&self) -> bool
fn write(&mut self, s: impl AsRef<str>) -> Result<()>
fn rewrite(&mut self, s: impl AsRef<str>) -> Result<()>
fn write_line(&self, s: impl AsRef<str>) -> Result<()>
Object Safety§
This trait is not object safe.