de.bb.util
Class LogFile

java.lang.Object
  extended by de.bb.util.LogFile

public class LogFile
extends java.lang.Object

Provides simple log facilities. These are:


Constructor Summary
LogFile(java.lang.String bn)
          Create a LogFile using the specified base name.
LogFile(java.lang.String bn, java.lang.String fmt)
          Create a LogFile using the specified base name.
 
Method Summary
 void write(java.lang.String msg)
          Append a message to the log file.
 void writeDate(java.lang.String msg)
          Append a message to the log file and add a date/time stamp.
 void writeln(byte[] msg)
          Append a message to the log file.
 void writeln(java.lang.String msg)
          Append a message to the log file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LogFile

public LogFile(java.lang.String bn)
Create a LogFile using the specified base name. The actual date is always added to the base name, and each day a new log file is created. If * is used as base name, stdout is used for output.

Parameters:
bn - the log files base name

LogFile

public LogFile(java.lang.String bn,
               java.lang.String fmt)
Create a LogFile using the specified base name. The actual date is always added to the base name, and each day a new log file is created. If * is used as base name, stdout is used for output.

Parameters:
bn - the log files base name
fmt - the date format which is appended to the basename
Method Detail

writeDate

public void writeDate(java.lang.String msg)
Append a message to the log file and add a date/time stamp.

Parameters:
msg - the message

writeln

public void writeln(java.lang.String msg)
Append a message to the log file.

Parameters:
msg - the message

writeln

public void writeln(byte[] msg)
Append a message to the log file.

Parameters:
msg - the message

write

public void write(java.lang.String msg)
Append a message to the log file.

Parameters:
msg - the message