Level
@frozen
public enum Level : Int, CaseIterable, Hashable, SelfIdentifiable
A value representing a log level.
-
The log level used for fined-grained debugging messages.
This level is the lowest one (i.e. the least important).
Declaration
Swift
case verbose = 1
-
The log level used for debugging messages.
Declaration
Swift
case debug = 2
-
The log level used for informational messages.
Declaration
Swift
case info = 3
-
The log level that signals an event that might possibly lead to an error.
Declaration
Swift
case warning = 4
-
The log level that signals a possibly recoverable error.
Declaration
Swift
case error = 5
-
The log level that signals a severe error that prevents the application from continuing.
This level is the greatest one (i.e. the most important).
Declaration
Swift
case fault = 6
-
The pretty name of this level.
Declaration
Swift
public var prettyName: String { get }
-
The emoji associated to this log level.
Declaration
Swift
public var emoji: String { get }
-
The system log level corresponding to this log level.
The same system log level may be used for several distinct log levels.
Declaration
Swift
public var osLogType: OSLogType { get }
-
Returns a boolean value indicating whether the left level is more important than or equal to the right level.
When the right level is
nil
, this operator returnsfalse
whatever the left level is.The most important level is
.fault
and the least important one is.verbose
.Declaration
Swift
public static func >= (left: Level, right: Level?) -> Bool
Parameters
left
The left level to compare.
right
The right level to compare or
nil
.