pub struct State {
pub options: LogOptions,
/* private fields */
}Fields§
§options: LogOptionsImplementations§
Source§impl State
impl State
pub fn new(module: Module, options: LogOptions) -> Self
Sourcepub fn cont_buffered_log(&self, text: &str)
pub fn cont_buffered_log(&self, text: &str)
Append more text to the previously buffered log.
The text may or may not end with a newline.
§Panics
Panics if the internal mutex is poisoned.
Sourcepub fn buffer_non_cont(&self, level: ggml_log_level, text: &str)
pub fn buffer_non_cont(&self, level: ggml_log_level, text: &str)
Start buffering a message. Not the CONT log level and text is missing a newline.
§Panics
Panics if the internal mutex is poisoned.
Sourcepub fn emit_non_cont_line(&self, level: ggml_log_level, text: &str)
pub fn emit_non_cont_line(&self, level: ggml_log_level, text: &str)
Emit a normal unbuffered log message (not the CONT log level and the text ends with a newline).
§Panics
Panics if the internal mutex is poisoned.
pub fn update_previous_level_for_disabled_log(&self, level: ggml_log_level)
Sourcepub fn is_enabled_for_level(&self, level: ggml_log_level) -> bool
pub fn is_enabled_for_level(&self, level: ggml_log_level) -> bool
Checks whether the given log level is enabled by the current tracing subscriber.
Auto Trait Implementations§
impl !Freeze for State
impl RefUnwindSafe for State
impl Send for State
impl Sync for State
impl Unpin for State
impl UnsafeUnpin for State
impl UnwindSafe for State
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