MasterLogger
@objcMembers
@objc(PESDKLogger)
public class MasterLogger : NSObject
The MasterLogger
manages and deploys loggers. That means it holds all instances of loggers, and delegates incoming log messages to each of them.
Also it takes case of threading, to keep logging efficient. More loggers can be added using the add
method.
All child loggers must implement the LoggerProtocol
.
-
Use this function to add your own logger.
Declaration
Swift
public static func add(logger: LoggerProtocol)
Parameters
logger
A logger.
-
Remove a logger.
Declaration
Swift
public static func remove(logger: LoggerProtocol)
Parameters
logger
The logger that should be removed.
-
Removed all loggers.
Declaration
Swift
public static func removeAll()
-
Logs an error.
Declaration
Swift
public static func error(_ message: String)
Parameters
message
A message.
-
Logs a warning.
Declaration
Swift
public static func warn(_ message: String)
Parameters
message
A message.
-
Logs an info level message.
Declaration
Swift
public static func info(_ message: String)
Parameters
message
A message.
-
Logs a debug level message.
Declaration
Swift
public static func debug(_ message: String)
Parameters
message
A message.