|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Logger
Logger
defines the methods which are used to create logging messages.
Logging levels are:
ERROR
WARN
INFO
TRACE_LOW
TRACE_MEDIUM
TRACE_HIGH
text(...)
methods. These
messages are generally hard-coded into the application.In addition, the following specialized methods are available to log trace information. Each of these trace methods is a convenience to the application programmer:
entry
exit
stackTrace
For performance reasons the method isLogging(int logLevel)
should be used
to check if a given logging level is written at all to the output. The method should
be used for the log message level entries, but is absolutely required to be called for
trace messages to avoid unnecessary round-trips and object creation.
Field Summary | |
---|---|
static int |
ERROR
Defines an error message. |
static int |
INFO
Defines an informational message. |
static int |
TRACE_HIGH
Defines a high-detail trace message. |
static int |
TRACE_LOW
Defines a low-detail trace message. |
static int |
TRACE_MEDIUM
Defines a medium-detail trace message. |
static int |
WARN
Defines a warning message. |
Method Summary | |
---|---|
void |
entry(int logLevel,
java.lang.String loggingMethod)
Logs entry into a method. |
void |
entry(int logLevel,
java.lang.String loggingMethod,
java.lang.Object parm1)
Logs entry into a method. |
void |
entry(int logLevel,
java.lang.String loggingMethod,
java.lang.Object[] parms)
Logs entry into a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod)
Logs exit from a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod,
boolean retValue)
Logs exit from a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod,
byte retValue)
Logs exit from a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod,
char retValue)
Logs exit from a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod,
double retValue)
Logs exit from a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod,
float retValue)
Logs exit from a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod,
int retValue)
Logs exit from a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod,
long retValue)
Logs exit from a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod,
java.lang.Object retValue)
Logs exit from a method. |
void |
exit(int logLevel,
java.lang.String loggingMethod,
short retValue)
Logs exit from a method. |
boolean |
isLogging(int logLevel)
Determines if this logger is logging data for a given log level or not. |
void |
stackTrace(int logLevel,
java.lang.String loggingMethod,
java.lang.String text)
Logs the call stack. |
void |
text(int logLevel,
java.lang.String loggingMethod,
java.lang.String text)
Logs a text message with no parameters. |
void |
text(int logLevel,
java.lang.String loggingMethod,
java.lang.String text,
java.lang.Object parm1)
Logs a text message with one parameter. |
void |
text(int logLevel,
java.lang.String loggingMethod,
java.lang.String text,
java.lang.Object[] parms)
Logs a text message with an array of parameters. |
void |
text(int logLevel,
java.lang.String loggingMethod,
java.lang.Throwable t,
java.lang.String text)
Logs a text message with no parameters. |
void |
text(int logLevel,
java.lang.String loggingMethod,
java.lang.Throwable t,
java.lang.String text,
java.lang.Object[] parms)
Logs a text message with an array of parameters. |
Field Detail |
---|
static final int ERROR
static final int WARN
static final int INFO
static final int TRACE_LOW
static final int TRACE_MEDIUM
static final int TRACE_HIGH
Method Detail |
---|
boolean isLogging(int logLevel)
logLevel
- The log level to be checked.
true
when the object is logging the log level;
false
otherwise.void text(int logLevel, java.lang.String loggingMethod, java.lang.String text)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.text
- The message text.void text(int logLevel, java.lang.String loggingMethod, java.lang.String text, java.lang.Object parm1)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.text
- The message text.parm1
- An element to be displayed with the message.void text(int logLevel, java.lang.String loggingMethod, java.lang.String text, java.lang.Object[] parms)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.text
- The message text.parms
- An array of elements to be displayed with the message.void text(int logLevel, java.lang.String loggingMethod, java.lang.Throwable t, java.lang.String text)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.t
- The throwable that is cause for this log entry.text
- The message text.void text(int logLevel, java.lang.String loggingMethod, java.lang.Throwable t, java.lang.String text, java.lang.Object[] parms)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.t
- The throwable that is cause for this log entry.text
- The message text.parms
- An array of elements to be displayed with the message.void entry(int logLevel, java.lang.String loggingMethod)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.void entry(int logLevel, java.lang.String loggingMethod, java.lang.Object parm1)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.parm1
- An element to be displayed as trace data.void entry(int logLevel, java.lang.String loggingMethod, java.lang.Object[] parms)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.parms
- An array of parameters passed to the method.void exit(int logLevel, java.lang.String loggingMethod)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.void exit(int logLevel, java.lang.String loggingMethod, byte retValue)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.retValue
- The returned value.void exit(int logLevel, java.lang.String loggingMethod, short retValue)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.retValue
- The returned value.void exit(int logLevel, java.lang.String loggingMethod, int retValue)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.retValue
- The returned value.void exit(int logLevel, java.lang.String loggingMethod, long retValue)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.retValue
- The returned value.void exit(int logLevel, java.lang.String loggingMethod, float retValue)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.retValue
- The returned value.void exit(int logLevel, java.lang.String loggingMethod, double retValue)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.retValue
- The returned value.void exit(int logLevel, java.lang.String loggingMethod, char retValue)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.retValue
- The returned value.void exit(int logLevel, java.lang.String loggingMethod, boolean retValue)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.retValue
- The returned value.void exit(int logLevel, java.lang.String loggingMethod, java.lang.Object retValue)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.retValue
- The returned value.void stackTrace(int logLevel, java.lang.String loggingMethod, java.lang.String text)
logLevel
- The level of the log entry.loggingMethod
- The name of the logging method.text
- The message text.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |