Package ru.bgerp.util

Class Log


  • public class Log
    extends java.lang.Object
    Logger wrapper with additional functions.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void debug​(java.lang.Object message)
      Runs #log(Priority, String) with Level.DEBUG
      void debug​(java.lang.String pattern, java.lang.Object... params)
      Runs log(Priority, String, Object...) with Level.DEBUG
      void error​(java.lang.Object message)
      Runs #log(Priority, String) with Level.ERROR
      void error​(java.lang.String pattern, java.lang.Object params)
      Runs log(Priority, String, Object...) with Level.ERROR
      void error​(java.lang.String message, java.lang.Throwable e)  
      void error​(java.lang.Throwable e)  
      static Log getLog()
      Returns caller class connected logger.
      static Log getLog​(java.lang.Class<?> clazz)
      Returns class connected logger.
      void info​(java.lang.Object message)
      Runs #log(Priority, String) with Level.INFO
      void info​(java.lang.String pattern, java.lang.Object... params)
      boolean isDebugEnabled()
      Checks if debug enabled.
      void log​(org.apache.log4j.Priority level, java.lang.Object message)
      Wrapper function for Logger.
      void warn​(java.lang.Object message)
      Runs #log(Priority, String) with Level.WARN
      void warn​(java.lang.String pattern, java.lang.Object... params)
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • getLog

        public static Log getLog​(java.lang.Class<?> clazz)
        Returns class connected logger.
        Parameters:
        clazz -
        Returns:
      • getLog

        public static Log getLog()
        Returns caller class connected logger.
        Returns:
      • debug

        public void debug​(java.lang.Object message)
        Runs #log(Priority, String) with Level.DEBUG
      • isDebugEnabled

        public boolean isDebugEnabled()
        Checks if debug enabled.
      • info

        public void info​(java.lang.Object message)
        Runs #log(Priority, String) with Level.INFO
      • warn

        public void warn​(java.lang.Object message)
        Runs #log(Priority, String) with Level.WARN
      • error

        public void error​(java.lang.Object message)
        Runs #log(Priority, String) with Level.ERROR
      • error

        public void error​(java.lang.Throwable e)
      • error

        public void error​(java.lang.String message,
                          java.lang.Throwable e)
      • log

        public final void log​(org.apache.log4j.Priority level,
                              java.lang.Object message)
        Wrapper function for Logger.
        Parameters:
        level -
        message -