pub struct Output { /* private fields */ }
Implementations§
source§impl Output
impl Output
pub fn new(out: Box<dyn Write>, err: Box<dyn Write>) -> Self
pub fn quiet(self, value: bool) -> Self
pub fn set_quiet(&mut self, value: bool)
pub fn verbose(self, value: bool) -> Self
pub fn set_verbose(&mut self, value: bool)
pub fn color(self, value: bool) -> Self
pub fn show(self, value: bool) -> Self
pub fn set_show(&mut self, value: bool)
pub fn format_table( &self, headers: &[&str], data: Vec<Vec<&str>>, preset: Option<&str> ) -> String
pub fn output(&mut self, output: impl Display) -> bool
pub fn notify(&mut self, message: &[ANSIString<'_>]) -> String
pub fn notify_str(&mut self, message: &str) -> String
pub fn notify_error( &mut self, code: ErrorCode, message: &[ANSIString<'_>] ) -> String
pub fn error_code(&self) -> Option<i32>
pub fn flush(&mut self) -> Result<()>
pub fn write_toml<I, T>( &mut self, file: &Path, document: &mut Document, heading: &str, values: I )where I: IntoIterator<Item = (T, Item)>, T: AsRef<str>,
pub fn create_file(&mut self, file: &Path) -> Result<(), String>
pub fn move_file( &mut self, source: &Path, dest: &Path, copy: bool ) -> Result<(), String>
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Output
impl !Send for Output
impl !Sync for Output
impl Unpin for Output
impl !UnwindSafe for Output
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more