Class LoggerAdapterConsole

java.lang.Object
org.spongepowered.asm.logging.LoggerAdapterAbstract
org.spongepowered.asm.logging.LoggerAdapterConsole
All Implemented Interfaces:
ILogger

public class LoggerAdapterConsole extends LoggerAdapterAbstract
A very basic logger adapter which does not log anything to file and simply emits formatted log messages to the console printstreams
  • Constructor Details

    • LoggerAdapterConsole

      public LoggerAdapterConsole(String name)
      Parameters:
      name - Logger name
  • Method Details

    • getType

      public String getType()
      Description copied from interface: ILogger
      Get a short human-readable name of this logger type
    • setDebugStream

      public LoggerAdapterConsole setDebugStream(PrintStream debug)
      Set output stream for DEBUG-level messages
      Parameters:
      debug - New PrintStream for debug messages
      Returns:
      fluent
    • catching

      public void catching(Level level, Throwable t)
      Description copied from interface: ILogger
      Logs an exception or error that has been caught.
      Parameters:
      level - The logging Level.
      t - The Throwable.
    • log

      public void log(Level level, String message, Object... params)
      Description copied from interface: ILogger
      Logs a message with parameters at the given level.
      Parameters:
      level - the logging level
      message - the message to log
      params - parameters to the message
    • log

      public void log(Level level, String message, Throwable t)
      Description copied from interface: ILogger
      Logs a message at the given level including the stack trace of the Throwable t passed as parameter.
      Parameters:
      level - the logging level
      message - the message to log
      t - the exception to log, including its stack trace
    • throwing

      public <T extends Throwable> T throwing(T t)
      Description copied from interface: ILogger
      Logs an exception or error to be thrown.
      Type Parameters:
      T - the Throwable type
      Parameters:
      t - The Throwable
      Returns:
      the Throwable