pub enum LogLevel {
Debug = 1,
Error = 4,
Info = 2,
Trace = 0,
Warn = 3,
Off = -1,
}
Variants§
Debug = 1
the debug designation (rank 1) often used for development
Error = 4
the error designation (rank 4) is used for errors that are not fatal to the program
Info = 2
the info designation (rank 2) is used for useful information
Trace = 0
the trace designation (rank 0) is used for very low-level (often extremely verbose) information
Warn = 3
The warn designation (rank 3)
Off = -1
the off designation (rank -1) is used to turn off logging
Implementations§
Source§impl LogLevel
impl LogLevel
Sourcepub const fn is_debug(&self) -> bool
pub const fn is_debug(&self) -> bool
Returns true if the enum is LogLevel::Debug otherwise false
Sourcepub const fn is_error(&self) -> bool
pub const fn is_error(&self) -> bool
Returns true if the enum is LogLevel::Error otherwise false
Source§impl LogLevel
impl LogLevel
pub fn from_isize(level: isize) -> LogLevel
Sourcepub fn is_enabled(&self) -> bool
pub fn is_enabled(&self) -> bool
returns true if the log-level is not Off
pub fn as_log_string<T>(&self, name: T) -> Stringwhere
T: Display,
Trait Implementations§
Source§impl<'de> Deserialize<'de> for LogLevel
impl<'de> Deserialize<'de> for LogLevel
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<LogLevel, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<LogLevel, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl IntoEnumIterator for LogLevel
impl IntoEnumIterator for LogLevel
type Iterator = LogLevelIter
fn iter() -> LogLevelIter ⓘ
Source§impl Ord for LogLevel
impl Ord for LogLevel
Source§impl PartialOrd for LogLevel
impl PartialOrd for LogLevel
Source§impl Serialize for LogLevel
impl Serialize for LogLevel
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Source§impl VariantNames for LogLevel
impl VariantNames for LogLevel
impl Copy for LogLevel
impl Eq for LogLevel
impl Send for LogLevel
impl StructuralPartialEq for LogLevel
impl Sync for LogLevel
Auto Trait Implementations§
impl Freeze for LogLevel
impl RefUnwindSafe for LogLevel
impl Unpin for LogLevel
impl UnwindSafe for LogLevel
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<T> Displayable for T
impl<T> Displayable for T
fn __private__(&self) -> Seal
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.