Package org.mariadb.jdbc.util.log
Class Loggers
- java.lang.Object
-
- org.mariadb.jdbc.util.log.Loggers
-
public final class Loggers extends java.lang.ObjectLoggers factory
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classLoggers.ConsoleLoggerFactoryprivate static classLoggers.JdkLoggerFactoryJDK wrapperprivate static interfaceLoggers.LoggerFactoryprivate static classLoggers.NoLoggerFactoryprivate static classLoggers.Slf4JLoggerFactory
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringCONSOLE_DEBUG_PROPERTYset if console must log debug levelstatic java.lang.StringFALLBACK_PROPERTYdefined if using JDK if sfl4j is not present.private static Loggers.LoggerFactoryLOGGER_FACTORYfactorystatic java.lang.StringNO_LOGGER_PROPERTYdisable loggingstatic java.lang.StringTEST_ENABLE_SLF4J!! testing only !! permit to disable SLF4J implementation even if SLF4j is present
-
Constructor Summary
Constructors Constructor Description Loggers()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static LoggergetLogger(java.lang.Class<?> cls)Return default logger implementationstatic LoggergetLogger(java.lang.String name)Return default logger implementationstatic voidinit()Initialize factory
-
-
-
Field Detail
-
FALLBACK_PROPERTY
public static final java.lang.String FALLBACK_PROPERTY
defined if using JDK if sfl4j is not present. possible values: JDK/CONSOLE- See Also:
- Constant Field Values
-
CONSOLE_DEBUG_PROPERTY
public static final java.lang.String CONSOLE_DEBUG_PROPERTY
set if console must log debug level- See Also:
- Constant Field Values
-
TEST_ENABLE_SLF4J
public static final java.lang.String TEST_ENABLE_SLF4J
!! testing only !! permit to disable SLF4J implementation even if SLF4j is present- See Also:
- Constant Field Values
-
NO_LOGGER_PROPERTY
public static final java.lang.String NO_LOGGER_PROPERTY
disable logging- See Also:
- Constant Field Values
-
LOGGER_FACTORY
private static Loggers.LoggerFactory LOGGER_FACTORY
factory
-
-
Method Detail
-
getLogger
public static Logger getLogger(java.lang.String name)
Return default logger implementation- Parameters:
name- logger name- Returns:
- logger implementation
-
getLogger
public static Logger getLogger(java.lang.Class<?> cls)
Return default logger implementation- Parameters:
cls- class- Returns:
- logger implementation
-
init
public static void init()
Initialize factory
-
-