Class SystemLogger

java.lang.Object
org.nineml.logging.Logger
org.nineml.logging.SystemLogger

public class SystemLogger extends Logger
The system logger routes messages to another logging framework.

This class supports either configuration with org.slf4j.Logger or configuration directly with a java.util.logging.Logger.

This logger makes it easy to configure logging through a standard logging framework, as might be present on a Java application server. By default the logger uses the org.slf4j.LoggerFactory to create a logger. This logger can be supported at runtime by a wide variety of concrete backend classes. For details on how SLF4J finds a logging backend, see their documentation.

Alternatively, if you instantiate the SystemLogger with a java.util.logging.Logger directly, it will use that.

  • Constructor Details

    • SystemLogger

      public SystemLogger()
    • SystemLogger

      public SystemLogger(Logger logger)
  • Method Details

    • error

      public void error(String category, String format, Object... params)
      Description copied from class: Logger
      Issue an error message.
      Specified by:
      error in class Logger
      Parameters:
      category - the message category
      format - the format string
      params - message parameters
    • warn

      public void warn(String category, String format, Object... params)
      Description copied from class: Logger
      Issue a warning message.
      Specified by:
      warn in class Logger
      Parameters:
      category - the message category
      format - the format string
      params - message parameters
    • info

      public void info(String category, String format, Object... params)
      Description copied from class: Logger
      Issue an informational message.
      Specified by:
      info in class Logger
      Parameters:
      category - the message category
      format - the format string
      params - message parameters
    • debug

      public void debug(String category, String format, Object... params)
      Description copied from class: Logger
      Issue a debug message.
      Specified by:
      debug in class Logger
      Parameters:
      category - the message category
      format - the format string
      params - message parameters
    • trace

      public void trace(String category, String format, Object... params)
      Description copied from class: Logger
      Issue a trace message.
      Specified by:
      trace in class Logger
      Parameters:
      category - the message category
      format - the format string
      params - message parameters