com.revusky.niggle.util
Class FileLog
java.lang.Object
|
+--com.revusky.niggle.util.FileLog
- All Implemented Interfaces:
- Log
- public class FileLog
- extends java.lang.Object
- implements Log
This class provides logging to a file. Entries are appended to the end of the file.
Constructor Summary |
FileLog(java.lang.String filename)
Intstantiant an instance for a given file. |
Method Summary |
java.lang.String |
getFilename()
|
void |
println(java.lang.Object o)
Append the o.toString() followed by a newline to the file. |
void |
setFilename(java.lang.String filename)
Set the value of the file. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LINE_SEPARATOR
public static final java.lang.String LINE_SEPARATOR
FileLog
public FileLog(java.lang.String filename)
- Intstantiant an instance for a given file. Determine system line separator
or use \n if all else fails.
setFilename
public final void setFilename(java.lang.String filename)
- Set the value of the file.
getFilename
public final java.lang.String getFilename()
println
public void println(java.lang.Object o)
- Append the o.toString() followed by a newline to the file.
- Specified by:
println
in interface Log