org.jivesoftware.spark.util.log
Class Log

java.lang.Object
  extended by org.jivesoftware.spark.util.log.Log

public class Log
extends java.lang.Object

Creates and writes out messages to a a log file. This should be used for all error handling within the Agent application.


Method Summary
static void debug(java.lang.String message)
          Logs all messages to standard errout for debugging purposes.
static void error(java.lang.String message)
          Logs all error messages to default error logger.
static void error(java.lang.String message, java.lang.Throwable ex)
          Logs all error messages to default error logger.
static void error(java.lang.Throwable ex)
          Logs all error messages to default error logger.
static void warning(java.lang.String message)
           
static void warning(java.lang.String message, java.lang.Throwable ex)
          Log a warning message to the default logger.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

error

public static void error(java.lang.String message,
                         java.lang.Throwable ex)
Logs all error messages to default error logger.

Parameters:
message - a message to append to log file.
ex - the exception being thrown.

error

public static void error(java.lang.Throwable ex)
Logs all error messages to default error logger.

Parameters:
ex - the exception being thrown.

warning

public static void warning(java.lang.String message,
                           java.lang.Throwable ex)
Log a warning message to the default logger.

Parameters:
message - the message to log.
ex - the exception.

warning

public static void warning(java.lang.String message)

error

public static void error(java.lang.String message)
Logs all error messages to default error logger.

Parameters:
message - a message to append to log file.

debug

public static void debug(java.lang.String message)
Logs all messages to standard errout for debugging purposes. To use, pass in the VM Parameters debug.mode=true.

ex. (-Ddebug.mode=true)

Parameters:
message - the message to print out.