Package wt.util

Class DebugWriter

java.lang.Object
wt.util.DebugWriter
All Implemented Interfaces:
Serializable

public class DebugWriter extends Object implements Serializable
This class provides standard methods for reporting various categories of information to aid in debugging. No static methods should be added to this class, since that makes it much more difficult to promote it to an interface, if this becomes desireable in the future.

Supported API: true

Extendable: false
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    report(String message)
    Reports the passed message.
    void
    setLogFile(String name, boolean append, boolean tee, int iterations, String date_format, boolean add_thread)
    Deprecated. 
    void
    setLogFile(String name, boolean append, boolean tee, int iterations, String date_format, boolean add_thread, boolean verbose)
    Sets the log file output parameters.

    Methods inherited from class java.lang.Object

    clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Method Details

    • report

      public void report(String message)
      Reports the passed message.

      Supported API: true
      Parameters:
      message - the text to report
    • setLogFile

      public void setLogFile(String name, boolean append, boolean tee, int iterations, String date_format, boolean add_thread)
      Deprecated.
      Sets the log file output parameters. If this object is already pointing to a log file, it will be redirected based on the parameters. If the file name passed is the same as log file already pointed to, none of the parameters will be changed.

      Supported API: true
      Parameters:
      name - the name of the log file, including full directory specification.
      append - if true, opens the log file in append mode.
      tee - if true, will also send all output to standard output
      iterations - if a value greater than zero is passed, will iterate file name up to the number specified. (e.g. file1, file2, file3...)
      date_format - if a date format is passed, it will be used in prefixing each line with a time stamp; if nothing is provided, the lines will not be prefixed with a time stamp.
      add_thread - if true, each output line will include the name of the thread being executed.
    • setLogFile

      public void setLogFile(String name, boolean append, boolean tee, int iterations, String date_format, boolean add_thread, boolean verbose)
      Sets the log file output parameters. If this object is already pointing to a log file, it will be redirected based on the parameters. If the file name passed is the same as log file already pointed to, none of the parameters will be changed.

      Supported API: true
      Parameters:
      name - the name of the log file, including full directory specification.
      append - if true, opens the log file in append mode.
      tee - if true, will also send all output to standard output
      iterations - if a value greater than zero is passed, will iterate file name up to the number specified. (e.g. file1, file2, file3...)
      date_format - if a date format is passed, it will be used in prefixing each line with a time stamp; if nothing is provided, the lines will not be prefixed with a time stamp.
      add_thread - if true, each output line will include the name of the thread being executed.
      verbose - if true, will use the most verbose option for info reporting, but may only apply to certain method.