Class BacktraceLogger

java.lang.Object
backtraceio.library.logger.BacktraceLogger

public class BacktraceLogger extends Object
Backtrace Logger class for logging messages from inside library
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static int
    d(String tag, String message)
     
    static int
    e(String tag, String message)
    Log messages that suggest error or something that should not happen
    static int
    e(String tag, String message, Throwable tr)
    Log messages that suggest error or something that should not happen
    static void
    set logging level from which all messages should be logged to the console
    static int
    w(String tag, String message)
    Log messages that suggest something unexpected or rare has happened, which isn't an error.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • BacktraceLogger

      public BacktraceLogger()
  • Method Details

    • setLevel

      public static void setLevel(LogLevel level)
      set logging level from which all messages should be logged to the console
      Parameters:
      level - login level
    • d

      public static int d(String tag, String message)
      Parameters:
      tag - source of logs, usually identifies the class or activity
      message - text information which should be logged
      Returns:
      the number of bytes written
    • w

      public static int w(String tag, String message)
      Log messages that suggest something unexpected or rare has happened, which isn't an error.
      Parameters:
      tag - source of logs, usually identifies the class or activity
      message - text information which should be logged
      Returns:
      the number of bytes written
    • e

      public static int e(String tag, String message)
      Log messages that suggest error or something that should not happen
      Parameters:
      tag - source of logs, usually identifies the class or activity
      message - text information which should be logged
      Returns:
      the number of bytes written
    • e

      public static int e(String tag, String message, Throwable tr)
      Log messages that suggest error or something that should not happen
      Parameters:
      tag - source of logs, usually identifies the class or activity
      message - text information which should be logged
      tr - an exception to log
      Returns:
      the number of bytes written