com.arjuna.common.util.logging
Interface LogNoi18n


public interface LogNoi18n

Non-internationalised logging interface abstracting the various logging APIs supported by Arjuna CLF. Non-i18n messages should generally be debug (trace) level or raw exceptions. All textual messages at higher levels should go through the i18n logger instead. See Logi18n for an internationalised version and for more information.

The five logging levels used by Log are (in order):

  1. debug (the least serious
  2. info
  3. warn
  4. error
  5. fatal (the most serious)
The mapping of these log levels to the concepts used by the underlying logging system is implementation dependent. The implemention should ensure, though, that this ordering behaves as expected.

Performance is often a logging concern. By examining the appropriate property, a component can avoid expensive operations (producing information to be logged).

For example,

    if (log.isDebugEnabled()) {
        ... do something expensive ...
        log.debug(theResult);
    }
 

Configuration of the underlying logging system will generally be done external to the Logging APIs, through whatever mechanism is supported by that system.

Version:
$Revision: 2342 $ $Date: 2006-03-30 14:06:17 +0100 (Thu, 30 Mar 2006) $
Author:
Thomas Rischbeck

Method Summary
 void debug(java.lang.String message)
          Log a message with the DEBUG Level Note: this method does not use i18n.
 void error(java.lang.Throwable message)
          Log a message with ERROR Level
 void fatal(java.lang.Throwable message)
          Log a message with FATAL Level
 void info(java.lang.Throwable message)
          Deprecated. exceptions at info level don't make a lot sense.
 boolean isDebugEnabled()
          Determine if this logger is enabled for DEBUG messages.
 boolean isErrorEnabled()
          Determine if this logger is enabled for ERROR messages.
 boolean isFatalEnabled()
          Determine if this logger is enabled for FATAL messages.
 boolean isInfoEnabled()
          Determine if this logger is enabled for INFO messages.
 boolean isWarnEnabled()
          Determine if this logger is enabled for WARN messages.
 void warn(java.lang.Throwable message)
          Log a message with WARN Level
 

Method Detail

isDebugEnabled

boolean isDebugEnabled()
Determine if this logger is enabled for DEBUG messages. This method returns true when the underlying logger is configured with DEBUG level on.

Returns:
True if the logger is enabled for DEBUG, false otherwise

isInfoEnabled

boolean isInfoEnabled()
Determine if this logger is enabled for INFO messages.

Returns:
True if the logger is enabled for INFO, false otherwise

isWarnEnabled

boolean isWarnEnabled()
Determine if this logger is enabled for WARN messages.

Returns:
True if the logger is enabled for WARN, false otherwise

isErrorEnabled

boolean isErrorEnabled()
Determine if this logger is enabled for ERROR messages.

Returns:
True if the logger is enabled for ERROR, false otherwise

isFatalEnabled

boolean isFatalEnabled()
Determine if this logger is enabled for FATAL messages.

Returns:
True if the logger is enabled for FATAL, false otherwise

info

void info(java.lang.Throwable message)
Deprecated. exceptions at info level don't make a lot sense.

Log a message with INFO Level

Parameters:
message - the message to log

warn

void warn(java.lang.Throwable message)
Log a message with WARN Level

Parameters:
message - the message to log

error

void error(java.lang.Throwable message)
Log a message with ERROR Level

Parameters:
message - the message to log

fatal

void fatal(java.lang.Throwable message)
Log a message with FATAL Level

Parameters:
message - the message to log

debug

void debug(java.lang.String message)
Log a message with the DEBUG Level Note: this method does not use i18n. ie, message is directly used for log output.

Parameters:
message - The message to log.