Package org.jooq.tools
Class JooqLogger
- java.lang.Object
-
- org.jooq.tools.JooqLogger
-
- All Implemented Interfaces:
Log
public final class JooqLogger extends java.lang.Object implements Log
The jOOQ logger abstraction.This logger provides abstraction over the three logger APIs supported optionally by jOOQ. These are (in order of preference):
- slf4j
- log4j
- jav.util.logging
JooqLogger
tries to instantiate any of the above loggers, catching potentialNoClassDefFoundError
's in case any logger API cannot be found on the classpath.- Author:
- Lukas Eder
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
JooqLogger.Level
Deprecated.- UseLog.Level
instead
-
Constructor Summary
Constructors Constructor Description JooqLogger()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
debug(java.lang.Object message)
Log a message inDEBUG
level.void
debug(java.lang.Object message, java.lang.Object details)
Log a message inDEBUG
level.void
debug(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inDEBUG
level.void
debug(java.lang.Object message, java.lang.Throwable throwable)
Log a message inDEBUG
level.void
error(java.lang.Object message)
Log a message inERROR
level.void
error(java.lang.Object message, java.lang.Object details)
Log a message inERROR
level.void
error(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inERROR
level.void
error(java.lang.Object message, java.lang.Throwable throwable)
Log a message inERROR
level.static JooqLogger
getLogger(java.lang.Class<?> clazz)
Get a logger wrapper for a class.static void
globalThreshold(Log.Level level)
Set a global level threshold to all JooqLoggers.static void
globalThreshold(JooqLogger.Level level)
Set a global level threshold to all JooqLoggers.void
info(java.lang.Object message)
Log a message inINFO
level.void
info(java.lang.Object message, java.lang.Object details)
Log a message inINFO
level.void
info(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inINFO
level.void
info(java.lang.Object message, java.lang.Throwable throwable)
Log a message inINFO
level.boolean
isDebugEnabled()
Check ifDEBUG
level logging is enabled.boolean
isInfoEnabled()
Check ifINFO
level logging is enabled.boolean
isTraceEnabled()
Check ifTRACE
level logging is enabled.void
trace(java.lang.Object message)
Log a message inTRACE
level.void
trace(java.lang.Object message, java.lang.Object details)
Log a message inTRACE
level.void
trace(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inTRACE
level.void
trace(java.lang.Object message, java.lang.Throwable throwable)
Log a message inTRACE
level.void
warn(java.lang.Object message)
Log a message inWARN
level.void
warn(java.lang.Object message, java.lang.Object details)
Log a message inWARN
level.void
warn(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inWARN
level.void
warn(java.lang.Object message, java.lang.Throwable throwable)
Log a message inWARN
level.
-
-
-
Method Detail
-
getLogger
public static JooqLogger getLogger(java.lang.Class<?> clazz)
Get a logger wrapper for a class.
-
isTraceEnabled
public boolean isTraceEnabled()
Check ifTRACE
level logging is enabled.- Specified by:
isTraceEnabled
in interfaceLog
-
trace
public void trace(java.lang.Object message)
Log a message inTRACE
level.
-
trace
public void trace(java.lang.Object message, java.lang.Object details)
Log a message inTRACE
level.
-
trace
public void trace(java.lang.Object message, java.lang.Throwable throwable)
Log a message inTRACE
level.
-
trace
public void trace(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inTRACE
level.
-
isDebugEnabled
public boolean isDebugEnabled()
Check ifDEBUG
level logging is enabled.- Specified by:
isDebugEnabled
in interfaceLog
-
debug
public void debug(java.lang.Object message)
Log a message inDEBUG
level.
-
debug
public void debug(java.lang.Object message, java.lang.Object details)
Log a message inDEBUG
level.
-
debug
public void debug(java.lang.Object message, java.lang.Throwable throwable)
Log a message inDEBUG
level.
-
debug
public void debug(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inDEBUG
level.
-
isInfoEnabled
public boolean isInfoEnabled()
Check ifINFO
level logging is enabled.- Specified by:
isInfoEnabled
in interfaceLog
-
info
public void info(java.lang.Object message)
Log a message inINFO
level.
-
info
public void info(java.lang.Object message, java.lang.Object details)
Log a message inINFO
level.
-
info
public void info(java.lang.Object message, java.lang.Throwable throwable)
Log a message inINFO
level.
-
info
public void info(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inINFO
level.
-
warn
public void warn(java.lang.Object message)
Log a message inWARN
level.
-
warn
public void warn(java.lang.Object message, java.lang.Object details)
Log a message inWARN
level.
-
warn
public void warn(java.lang.Object message, java.lang.Throwable throwable)
Log a message inWARN
level.
-
warn
public void warn(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inWARN
level.
-
error
public void error(java.lang.Object message)
Log a message inERROR
level.
-
error
public void error(java.lang.Object message, java.lang.Object details)
Log a message inERROR
level.
-
error
public void error(java.lang.Object message, java.lang.Throwable throwable)
Log a message inERROR
level.
-
error
public void error(java.lang.Object message, java.lang.Object details, java.lang.Throwable throwable)
Log a message inERROR
level.
-
globalThreshold
public static void globalThreshold(JooqLogger.Level level)
Set a global level threshold to all JooqLoggers.
-
globalThreshold
public static void globalThreshold(Log.Level level)
Set a global level threshold to all JooqLoggers.
-
-