public abstract class AbstractInternalLogger extends java.lang.Object implements InternalLogger, java.io.Serializable
InternalLogger. This class implements
all methods that have a InternalLogLevel parameter by default to call
specific logger methods such as InternalLogger.info(String) or InternalLogger.isInfoEnabled().| 限定符 | 构造器和说明 |
|---|---|
protected |
AbstractInternalLogger(java.lang.String name)
Creates a new instance.
|
| 限定符和类型 | 方法和说明 |
|---|---|
void |
debug(java.lang.Throwable t)
Log an exception (throwable) at the DEBUG level.
|
void |
error(java.lang.Throwable t)
Log an exception (throwable) at the ERROR level.
|
void |
info(java.lang.Throwable t)
Log an exception (throwable) at the INFO level.
|
boolean |
isEnabled(InternalLogLevel level)
Is the logger instance enabled for the specified
level? |
void |
log(InternalLogLevel level,
java.lang.String msg)
Log a message at the specified
level. |
void |
log(InternalLogLevel level,
java.lang.String format,
java.lang.Object... arguments)
Log a message at the specified
level according to the specified format
and arguments. |
void |
log(InternalLogLevel level,
java.lang.String format,
java.lang.Object arg)
Log a message at the specified
level according to the specified format
and argument. |
void |
log(InternalLogLevel level,
java.lang.String format,
java.lang.Object argA,
java.lang.Object argB)
Log a message at the specified
level according to the specified format
and arguments. |
void |
log(InternalLogLevel level,
java.lang.String msg,
java.lang.Throwable cause)
Log an exception (throwable) at the specified
level with an
accompanying message. |
void |
log(InternalLogLevel level,
java.lang.Throwable cause)
Log an exception (throwable) at the specified
level. |
java.lang.String |
name()
Return the name of this
InternalLogger instance. |
protected java.lang.Object |
readResolve() |
java.lang.String |
toString() |
void |
trace(java.lang.Throwable t)
Log an exception (throwable) at the TRACE level.
|
void |
warn(java.lang.Throwable t)
Log an exception (throwable) at the WARN level.
|
protected AbstractInternalLogger(java.lang.String name)
public java.lang.String name()
InternalLoggerInternalLogger instance.name 在接口中 InternalLoggerpublic boolean isEnabled(InternalLogLevel level)
InternalLoggerlevel?isEnabled 在接口中 InternalLoggerlevel,
false otherwise.public void trace(java.lang.Throwable t)
InternalLoggertrace 在接口中 InternalLoggert - the exception (throwable) to logpublic void debug(java.lang.Throwable t)
InternalLoggerdebug 在接口中 InternalLoggert - the exception (throwable) to logpublic void info(java.lang.Throwable t)
InternalLoggerinfo 在接口中 InternalLoggert - the exception (throwable) to logpublic void warn(java.lang.Throwable t)
InternalLoggerwarn 在接口中 InternalLoggert - the exception (throwable) to logpublic void error(java.lang.Throwable t)
InternalLoggererror 在接口中 InternalLoggert - the exception (throwable) to logpublic void log(InternalLogLevel level, java.lang.String msg, java.lang.Throwable cause)
InternalLoggerlevel with an
accompanying message.log 在接口中 InternalLoggermsg - the message accompanying the exceptioncause - the exception (throwable) to logpublic void log(InternalLogLevel level, java.lang.Throwable cause)
InternalLoggerlevel.log 在接口中 InternalLoggercause - the exception (throwable) to logpublic void log(InternalLogLevel level, java.lang.String msg)
InternalLoggerlevel.log 在接口中 InternalLoggermsg - the message string to be loggedpublic void log(InternalLogLevel level, java.lang.String format, java.lang.Object arg)
InternalLoggerlevel according to the specified format
and argument.
This form avoids superfluous object creation when the logger
is disabled for the specified level.
log 在接口中 InternalLoggerformat - the format stringarg - the argumentpublic void log(InternalLogLevel level, java.lang.String format, java.lang.Object argA, java.lang.Object argB)
InternalLoggerlevel according to the specified format
and arguments.
This form avoids superfluous object creation when the logger
is disabled for the specified level.
log 在接口中 InternalLoggerformat - the format stringargA - the first argumentargB - the second argumentpublic void log(InternalLogLevel level, java.lang.String format, java.lang.Object... arguments)
InternalLoggerlevel according to the specified format
and arguments.
This form avoids superfluous string concatenation when the logger
is disabled for the specified level. However, this variant incurs the hidden
(and relatively small) cost of creating an Object[] before invoking the method,
even if this logger is disabled for the specified level. The variants taking
one and
two arguments exist solely
in order to avoid this hidden cost.
log 在接口中 InternalLoggerformat - the format stringarguments - a list of 3 or more argumentsprotected java.lang.Object readResolve()
throws java.io.ObjectStreamException
java.io.ObjectStreamExceptionpublic java.lang.String toString()
toString 在类中 java.lang.Object