edu.stanford.ejalbert.testing
Class TestAppLogger

java.lang.Object
  extended bynet.sf.wraplog.AbstractLogger
      extended byedu.stanford.ejalbert.testing.TestAppLogger

class TestAppLogger
extends AbstractLogger

Implements a logger for the test application. The log messages are sent to a JTextArea.


Constructor Summary
TestAppLogger(JTextArea debugTextArea, String[] levelLabels, String dateFormat)
           
 
Method Summary
 String[] getLevelOptions()
           
 String getLevelText()
           
protected  void reallyLog(int logLevel, String message, Throwable error)
          Logs a message and optional error details.
 
Methods inherited from class net.sf.wraplog.AbstractLogger
checkLevel, debug, debug, error, error, getLevel, getLoggedMessageCount, info, info, isDebugEnabled, isEnabled, isErrorEnabled, isInfoEnabled, isWarnEnabled, log, log, setLevel, warn, warn
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TestAppLogger

public TestAppLogger(JTextArea debugTextArea,
                     String[] levelLabels,
                     String dateFormat)
Method Detail

reallyLog

protected void reallyLog(int logLevel,
                         String message,
                         Throwable error)
                  throws Exception
Logs a message and optional error details.

Specified by:
reallyLog in class AbstractLogger
Parameters:
logLevel - one of: Level.DEBUG, Level.INFO, Level.WARN, Level.ERROR
message - the actual message; this will never be null
error - an error that is related to the message; unless null, the name and stack trace of the error are logged
Throws:
Exception

getLevelText

public String getLevelText()

getLevelOptions

public String[] getLevelOptions()