Enum celp_sdk::logger::log::SDKLogLevel
source · pub enum SDKLogLevel {
Critical,
Error,
Warning,
Info,
Debug,
}Expand description
SDK Log Level Enum
Variants§
Critical
A critical error. Maps to “Error” in log crate.
Error
A standard error. Maps to “Warn” in log crate.
Warning
A warning. Maps to “Info” in log crate.
Info
An informative message. Logs to “Debug” in log crate.
Debug
A debug message. Maps to “Trace” in log crate.
Implementations§
source§impl SDKLogLevel
impl SDKLogLevel
SDKLogLevel implementation
sourcepub fn max() -> SDKLogLevel
pub fn max() -> SDKLogLevel
Returns max logging level available.
sourcepub fn min() -> SDKLogLevel
pub fn min() -> SDKLogLevel
Returns min logging level available.
sourcepub fn as_str(&self) -> &'static str
pub fn as_str(&self) -> &'static str
Returns the converted string value of the SDKLogLevel enum.
pub fn from_usize(u: usize) -> Option<SDKLogLevel>
Trait Implementations§
source§impl Clone for SDKLogLevel
impl Clone for SDKLogLevel
source§fn clone(&self) -> SDKLogLevel
fn clone(&self) -> SDKLogLevel
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for SDKLogLevel
impl Debug for SDKLogLevel
source§impl Display for SDKLogLevel
impl Display for SDKLogLevel
source§impl From<Level> for SDKLogLevel
impl From<Level> for SDKLogLevel
Same as above, but the other way around.
source§impl From<SDKLogLevel> for Level
impl From<SDKLogLevel> for Level
Implement ‘From’ and ‘Into’ functionality to convert the Log levels we like to the levels that the crate uses. This means we can do something like: ‘let log_level: Level = SDKLogLevel::Info.into();’
source§fn from(sdk_ll: SDKLogLevel) -> Self
fn from(sdk_ll: SDKLogLevel) -> Self
source§impl FromStr for SDKLogLevel
impl FromStr for SDKLogLevel
source§fn from_str(level: &str) -> Result<SDKLogLevel, Self::Err>
fn from_str(level: &str) -> Result<SDKLogLevel, Self::Err>
Retrieve the SDK log value from a string value that is the integer value of the SDK log level. For example, “3” would return SDKLogLevel::Warning.