Interface ILogger

  • All Known Implementing Classes:
    Logger

    public interface ILogger
    API for logging messages with different levels. The most methods are able to handle a formated message and a variable number of parameters.

    The following example shows the possibilities of MessageFormat:

     info("The disk \"{0}\" contains ''{1}'' file(s).", "MyDisk", 27);
     
    The log output with different values for fileCount:
     The disk "MyDisk" contains '27' file(s).
     
    See MessageFormat fore more details.
    Since:
    10.01.2011
    API:
    This is a public API.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void debug​(String formatedMessage, Object... args)
      Formats and logs a message with level DEBUG.
      void debug​(String formatedMessage, Throwable throwable, Object... args)
      Formats and logs a message with level DEBUG.
      void error​(Object message)
      Logs a message with level ERROR.
      void error​(String formatedMessage, Object... args)
      Formats and logs a message with level ERROR.
      void error​(String formatedMessage, Throwable throwable, Object... args)
      Formats and logs a message with level ERROR.
      void fatal​(String formatedMessage, Object... args)
      Formats and logs a message with level FATAL.
      void fatal​(String formatedMessage, Throwable throwable, Object... args)
      Formats and logs a message with level FATAL.
      void info​(Object message)
      Logs a message with level INFO.
      void info​(String formatedMessage, Object... args)
      Formats(java.text.MessageFormat) and logs a message with level INFO.
      void info​(String formatedMessage, Throwable throwable, Object... args)
      Formats(java.text.MessageFormat) and logs a message with level INFO including a throwable.
      void log​(org.apache.log4j.Priority level, String formatedMessage, Object... args)
      Formats(java.text.MessageFormat) and logs a message.
      void log​(org.apache.log4j.Priority level, String formatedMessage, Throwable throwable, Object... args)
      Formats(java.text.MessageFormat) and logs a message.
      void warn​(Object message)
      Logs a message with level WARN.
      void warn​(String formatedMessage, Object... args)
      Formats and logs a message with level WARNING.
      void warn​(String formatedMessage, Throwable throwable, Object... args)
      Formats and logs a message with level WARNING.
    • Method Detail

      • debug

        void debug​(String formatedMessage,
                   Object... args)
        Formats and logs a message with level DEBUG.
        Parameters:
        formatedMessage - message including format tokens '{}'
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility NOVICE.
      • debug

        void debug​(String formatedMessage,
                   Throwable throwable,
                   Object... args)
        Formats and logs a message with level DEBUG.
        Parameters:
        formatedMessage - message including format tokens '{}'
        throwable - e.g. includes the exception
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility ADVANCED.
      • info

        void info​(Object message)
        Logs a message with level INFO.
        Parameters:
        message - if the message is an Throwable the stack trace is also logged.
        API:
        This public API is available in IvyScript and Java. It has the visibility NOVICE.
      • info

        void info​(String formatedMessage,
                  Object... args)
        Formats(java.text.MessageFormat) and logs a message with level INFO.
        Parameters:
        formatedMessage - message including format tokens '{}'
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility NOVICE.
      • info

        void info​(String formatedMessage,
                  Throwable throwable,
                  Object... args)
        Formats(java.text.MessageFormat) and logs a message with level INFO including a throwable.
        Parameters:
        formatedMessage - message including format tokens '{}'
        throwable - e.g. includes the exception
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility ADVANCED.
      • warn

        void warn​(Object message)
        Logs a message with level WARN.
        Parameters:
        message - if the message is an Throwable the stack trace is also logged.
        API:
        This public API is available in IvyScript and Java. It has the visibility NOVICE.
      • warn

        void warn​(String formatedMessage,
                  Object... args)
        Formats and logs a message with level WARNING.
        Parameters:
        formatedMessage - message including format tokens '{}'
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility NOVICE.
      • warn

        void warn​(String formatedMessage,
                  Throwable throwable,
                  Object... args)
        Formats and logs a message with level WARNING.
        Parameters:
        formatedMessage - message including format tokens '{}'
        throwable - e.g. includes the exception
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility ADVANCED.
      • error

        void error​(Object message)
        Logs a message with level ERROR.
        Parameters:
        message - if the message is an Throwable the stack trace is also logged
        API:
        This public API is available in IvyScript and Java. It has the visibility NOVICE.
      • error

        void error​(String formatedMessage,
                   Object... args)
        Formats and logs a message with level ERROR.
        Parameters:
        formatedMessage - message including format tokens '{}'
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility NOVICE.
      • error

        void error​(String formatedMessage,
                   Throwable throwable,
                   Object... args)
        Formats and logs a message with level ERROR.
        Parameters:
        formatedMessage - message including format tokens '{}'
        throwable - e.g. includes the exception
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility ADVANCED.
      • fatal

        void fatal​(String formatedMessage,
                   Object... args)
        Formats and logs a message with level FATAL.
        Parameters:
        formatedMessage - message including format tokens '{}'
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility ADVANCED.
      • fatal

        void fatal​(String formatedMessage,
                   Throwable throwable,
                   Object... args)
        Formats and logs a message with level FATAL.
        Parameters:
        formatedMessage - message including format tokens '{}'
        throwable - e.g. includes the exception
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility ADVANCED.
      • log

        void log​(org.apache.log4j.Priority level,
                 String formatedMessage,
                 Object... args)
        Formats(java.text.MessageFormat) and logs a message. Example: log("My {0} Message with {1} tokens.", "first", 2); --> log result: "My first Message with 2 tokens." After formating it calls the log method of org.apache.log4j.Logger
        Parameters:
        level - logging level see Priority
        formatedMessage - message including format tokens '{}'
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility ADVANCED.
      • log

        void log​(org.apache.log4j.Priority level,
                 String formatedMessage,
                 Throwable throwable,
                 Object... args)
        Formats(java.text.MessageFormat) and logs a message. Including a Throwable Object.
        Parameters:
        level - logging level see Priority
        formatedMessage - message including format tokens '{}'
        throwable - e.g. includes the exception
        args - token content
        API:
        This public API is available in IvyScript and Java. It has the visibility ADVANCED.