LoggerManager
Inheritance: java.lang.Object
public class LoggerManager
Static manager that controls the creation of loggers.
Constructors
Constructor | Description |
---|---|
LoggerManager() |
Methods
Method | Description |
---|---|
addLogger(String name, Logger logger) | Adds a logger to the LoggerManager with specified name. |
containsLogger(String name) | Determines whether the logger cache contains an object with the specified logger name. |
createLogger(String name, Appender appender) | Creates a logger with specified name and appender. |
createLogger(String name, Appender[] appenders) | Creates a logger with specified name and appender. |
createLogger(String name, LogLevel severity, Appender appender) | Creates a logger with specified name and appender. |
createLogger(String name, LogLevel severity, Appender[] appenders) | Creates a logger with specified name and appender. |
equals(Object arg0) | |
getClass() | |
getLogger(String name) | Gets a logger by the specified name. |
hashCode() | |
notify() | |
notifyAll() | |
removeLogger(String name) | Removes a logger with the specified name. |
toString() | |
wait() | |
wait(long arg0) | |
wait(long arg0, int arg1) |
LoggerManager()
public LoggerManager()
addLogger(String name, Logger logger)
public static void addLogger(String name, Logger logger)
Adds a logger to the LoggerManager with specified name.
Parameters:
Parameter | Type | Description |
---|---|---|
name | java.lang.String | The logger name. |
logger | Logger | The logger. |
containsLogger(String name)
public static boolean containsLogger(String name)
Determines whether the logger cache contains an object with the specified logger name.
Parameters:
Parameter | Type | Description |
---|---|---|
name | java.lang.String | The logger name. |
Returns: boolean - true if the logger cache contains an element with the key; otherwise, false.
createLogger(String name, Appender appender)
public static Logger createLogger(String name, Appender appender)
Creates a logger with specified name and appender.
Parameters:
Parameter | Type | Description |
---|---|---|
name | java.lang.String | The logger name. |
appender | Appender | The appender. |
Returns: Logger - The created logger.
createLogger(String name, Appender[] appenders)
public static Logger createLogger(String name, Appender[] appenders)
Creates a logger with specified name and appender.
Parameters:
Parameter | Type | Description |
---|---|---|
name | java.lang.String | The logger name. |
appenders | Appender[] | The appender. |
Returns: Logger - The created logger.
createLogger(String name, LogLevel severity, Appender appender)
public static Logger createLogger(String name, LogLevel severity, Appender appender)
Creates a logger with specified name and appender.
Parameters:
Parameter | Type | Description |
---|---|---|
name | java.lang.String | The logger name. |
severity | LogLevel | The severity. |
appender | Appender | The appender. |
Returns: Logger - The created logger.
createLogger(String name, LogLevel severity, Appender[] appenders)
public static Logger createLogger(String name, LogLevel severity, Appender[] appenders)
Creates a logger with specified name and appender.
Parameters:
Parameter | Type | Description |
---|---|---|
name | java.lang.String | The logger name. |
severity | LogLevel | The severity. |
appenders | Appender[] | The appenders array. |
Returns: Logger - The created logger.
equals(Object arg0)
public boolean equals(Object arg0)
Parameters:
Parameter | Type | Description |
---|---|---|
arg0 | java.lang.Object |
Returns: boolean
getClass()
public final native Class<?> getClass()
Returns: java.lang.Class
getLogger(String name)
public static Logger getLogger(String name)
Gets a logger by the specified name.
Parameters:
Parameter | Type | Description |
---|---|---|
name | java.lang.String | The logger name. |
Returns: Logger - The logger.
hashCode()
public native int hashCode()
Returns: int
notify()
public final native void notify()
notifyAll()
public final native void notifyAll()
removeLogger(String name)
public static void removeLogger(String name)
Removes a logger with the specified name.
Parameters:
Parameter | Type | Description |
---|---|---|
name | java.lang.String | The logger name. |
toString()
public String toString()
Returns: java.lang.String
wait()
public final void wait()
wait(long arg0)
public final native void wait(long arg0)
Parameters:
Parameter | Type | Description |
---|---|---|
arg0 | long |
wait(long arg0, int arg1)
public final void wait(long arg0, int arg1)
Parameters:
Parameter | Type | Description |
---|---|---|
arg0 | long | |
arg1 | int |