org.erights.e.develop.trace
Class TraceMessageStringifier

java.lang.Object
  |
  +--org.erights.e.develop.trace.TraceMessageStringifier

class TraceMessageStringifier
extends Object

This class is used to convert a trace message into a string. It is used (as opposed to toString()) when certain of the fields need to be omitted.

Future: IFC might allow the objects contained in trace messages to be displayed as special glyphs, even clickable buttons.

By default, everything is shown.


Field Summary
private  StringBuffer buffer
           
private  String lineSeparator
           
private  boolean myShowDate
           
private  boolean myShowLevel
           
private  boolean myShowLocation
           
private  boolean myShowSubsystem
           
private  boolean myShowTime
           
 
Constructor Summary
(package private) TraceMessageStringifier()
           
 
Method Summary
(package private)  void showDate(boolean value)
          Should the message include the date at which the message was created?
(package private)  void showLevel(boolean value)
          Should the message include an abbreviated description of the level at which the message was posted?
(package private)  void showLocation(boolean value)
          Should the message include the method name, file name, and line number?
(package private)  void showSubsystem(boolean value)
          Should the message include the subsystem name?
(package private)  void showTime(boolean value)
          Should the message include the time at which the message was created?
(package private)  String toString(TraceMessage message)
          Convert the given message into a string, obeying 'show' controls set earlier.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

myShowDate

private boolean myShowDate

myShowTime

private boolean myShowTime

myShowLocation

private boolean myShowLocation

myShowSubsystem

private boolean myShowSubsystem

myShowLevel

private boolean myShowLevel

lineSeparator

private final String lineSeparator

buffer

private final StringBuffer buffer
Constructor Detail

TraceMessageStringifier

TraceMessageStringifier()
Method Detail

showDate

void showDate(boolean value)
Should the message include the date at which the message was created?


showLevel

void showLevel(boolean value)
Should the message include an abbreviated description of the level at which the message was posted?


showLocation

void showLocation(boolean value)
Should the message include the method name, file name, and line number?


showSubsystem

void showSubsystem(boolean value)
Should the message include the subsystem name?


showTime

void showTime(boolean value)
Should the message include the time at which the message was created?


toString

String toString(TraceMessage message)
Convert the given message into a string, obeying 'show' controls set earlier.



comments?