pub struct TerminalIO { /* private fields */ }
Implementations§
Source§impl TerminalIO
impl TerminalIO
pub fn new(log_file: Option<OsString>) -> Result<Self, Error>
Sourcepub fn with_custom_logger(
log_file: Option<OsString>,
logger: Box<dyn Logger>,
) -> Result<Self, Error>
pub fn with_custom_logger( log_file: Option<OsString>, logger: Box<dyn Logger>, ) -> Result<Self, Error>
Creates a TerminalIO instance with a custom logger
This feature is only available if the custom-logging
feature is enabled
pub fn set_level(&mut self, level: Level)
pub fn log( &mut self, lvl: Level, txt: impl Into<String>, tag: impl Into<String>, )
pub fn log_stack_trace(&mut self, error: Box<dyn Error>, tag: impl Into<String>)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TerminalIO
impl !RefUnwindSafe for TerminalIO
impl !Send for TerminalIO
impl !Sync for TerminalIO
impl Unpin for TerminalIO
impl !UnwindSafe for TerminalIO
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