pub struct Log;Expand description
A struct for Android logging
Implementations§
Source§impl Log
impl Log
Sourcepub fn v<T>(msg: T)
pub fn v<T>(msg: T)
Log verbose message using the global tag If the global Log instance is not initialized, use the default tag [DEFAULT_TAG]
§Arguments
msg- The log message
Sourcepub fn d<T>(msg: T)
pub fn d<T>(msg: T)
Log debug message using the global tag If the global Log instance is not initialized, use the default tag [DEFAULT_TAG]
§Arguments
msg- The log message
Sourcepub fn i<T>(msg: T)
pub fn i<T>(msg: T)
Log info message using the global tag If the global Log instance is not initialized, use the default tag [DEFAULT_TAG]
§Arguments
msg- The log message
Sourcepub fn w<T>(msg: T)
pub fn w<T>(msg: T)
Log warn message using the global tag If the global Log instance is not initialized, use the default tag [DEFAULT_TAG]
§Arguments
msg- The log message
Sourcepub fn e<T>(msg: T)
pub fn e<T>(msg: T)
Log error message using the global tag If the global Log instance is not initialized, use the default tag [DEFAULT_TAG]
§Arguments
msg- The log message
Sourcepub fn init(tag: &str, mixinlog: bool)
pub fn init(tag: &str, mixinlog: bool)
Initialize the global Log instance with a specific tag
§Arguments
tag- The tag to be used for the global Log instancemixinlog- If true, set the Rust log crate to use this Log instance as the logger. e.g. log::info!(“message”)
Sourcepub fn is_enabled() -> bool
pub fn is_enabled() -> bool
Check if logging is enabled
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Log
impl RefUnwindSafe for Log
impl Send for Log
impl Sync for Log
impl Unpin for Log
impl UnwindSafe for Log
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