Class ConfigLogger
java.lang.Object
io.github.projectunified.craftconfig.common.ConfigLogger
Thin logger provider for CraftConfig.
By default, logs to
Logger.
Set a custom handler via set(Handler) to redirect logs.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceThe handler interface for processing log messagesstatic enumLog levels for CraftConfig -
Method Summary
Modifier and TypeMethodDescriptionstatic voidlog(ConfigLogger.LogLevel level, Class<?> clazz, String message, Throwable throwable) Log a message with throwablestatic voidset(ConfigLogger.Handler logHandler) Set a custom log handler.static voidLog a message at WARNING levelstatic voidLog a message with throwable at WARNING level
-
Method Details
-
set
Set a custom log handler.- Parameters:
logHandler- the handler, or null to reset to default
-
warn
Log a message at WARNING level- Parameters:
clazz- the calling classmessage- the message
-
warn
Log a message with throwable at WARNING level- Parameters:
clazz- the calling classmessage- the messagethrowable- the throwable
-
log
public static void log(ConfigLogger.LogLevel level, Class<?> clazz, String message, Throwable throwable) Log a message with throwable- Parameters:
level- the log levelclazz- the calling classmessage- the messagethrowable- the throwable
-