Class LoggerFactory
- java.lang.Object
-
- org.junit.platform.commons.logging.LoggerFactory
-
@API(status=INTERNAL, since="1.0") public final class LoggerFactory extends java.lang.ObjectFactory for theLoggerfacade for JUL.- Since:
- 1.0
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classLoggerFactory.DelegatingLogger
-
Field Summary
Fields Modifier and Type Field Description private static java.util.Set<LogRecordListener>listeners
-
Constructor Summary
Constructors Modifier Constructor Description privateLoggerFactory()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidaddListener(LogRecordListener listener)Add the suppliedLogRecordListenerto the set of registered listeners.static LoggergetLogger(java.lang.Class<?> clazz)Get aLoggerfor the specified class.static voidremoveListener(LogRecordListener listener)Remove the suppliedLogRecordListenerfrom the set of registered listeners.
-
-
-
Field Detail
-
listeners
private static final java.util.Set<LogRecordListener> listeners
-
-
Method Detail
-
getLogger
public static Logger getLogger(java.lang.Class<?> clazz)
Get aLoggerfor the specified class.- Parameters:
clazz- the class for which to get the logger; nevernull- Returns:
- the logger
-
addListener
public static void addListener(LogRecordListener listener)
Add the suppliedLogRecordListenerto the set of registered listeners.
-
removeListener
public static void removeListener(LogRecordListener listener)
Remove the suppliedLogRecordListenerfrom the set of registered listeners.
-
-