jmathlib.core.interpreter
Class ErrorLogger

java.lang.Object
  extended by jmathlib.core.interpreter.ErrorLogger

public class ErrorLogger
extends java.lang.Object

write error messages + debug information to a log file


Field Summary
private static boolean debugB
          flag for logging mode of JMathLib
private static java.lang.String indentS
          indent string
private static java.io.RandomAccessFile output
          handle to log file
 
Constructor Summary
ErrorLogger()
           
 
Method Summary
static void debugLine(double value)
          display a real value to the standard output
static void debugLine(int value)
          display an integer to the standard output
static void debugLine(java.lang.String text)
          display a debug line to the standard output and the file MathLib.log
static void decreaseIndent()
          Decreases the level of indent
static void displayStackTrace(java.lang.String message)
          Prints the current execution stack trace, the list of functions that have been called up to the current one.
 void finalize()
          Will release the file handle to the logfile
static boolean getDebug()
           
static void increaseIndent()
          Increases the level of indent
static void setDebug(boolean _debug)
          sets the debug flag
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

indentS

private static java.lang.String indentS
indent string


debugB

private static boolean debugB
flag for logging mode of JMathLib


output

private static java.io.RandomAccessFile output
handle to log file

Constructor Detail

ErrorLogger

public ErrorLogger()
Method Detail

getDebug

public static boolean getDebug()
Returns:
the setting of the debug flag

setDebug

public static void setDebug(boolean _debug)
sets the debug flag

Parameters:
_debug - = should debug information be displayed

debugLine

public static void debugLine(java.lang.String text)
display a debug line to the standard output and the file MathLib.log

Parameters:
text - = the text to display

finalize

public void finalize()
              throws java.lang.Throwable
Will release the file handle to the logfile

Overrides:
finalize in class java.lang.Object
Throws:
java.lang.Throwable

debugLine

public static void debugLine(int value)
display an integer to the standard output

Parameters:
value - = the number to display

debugLine

public static void debugLine(double value)
display a real value to the standard output

Parameters:
value - = the number to display

increaseIndent

public static void increaseIndent()
Increases the level of indent


decreaseIndent

public static void decreaseIndent()
Decreases the level of indent


displayStackTrace

public static void displayStackTrace(java.lang.String message)
Prints the current execution stack trace, the list of functions that have been called up to the current one.

Parameters:
message - = The message to display before the stack trace

FOOTER

BOTTOM