|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--ostore.util.Logger
A logging utility.
Each stage should open a Logger
with a good filename. Try
the ${InternalLog} variable in run-experiment.
If two stages open the same Logger
, their output will be
interleaved, but individual entries will remain atomic.
The backing file is wrapped in a BufferedWriter
for
efficient writes. Therefore new entries may not appear in the file instantly.
Method Summary | |
---|---|
void |
flush()
Flushes the log to disk. |
static void |
main(String[] args)
|
static Logger |
open(String filename)
Returns the Logger for the specified file. |
void |
write(String entry)
Appends an entry to the log file, adding a timestamp and newline. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static Logger open(String filename) throws IOException
Logger
for the specified file. This method
will create a new Logger
if necessary.
IOException
public static void main(String[] args) throws IOException
IOException
public void write(String entry)
IOException
s are ignored, for laziness.
public void flush()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |