org.globus.cog.karajan.workflow.nodes.restartLog
Class FlushableLockedFileWriter

java.lang.Object
  extended by java.io.Writer
      extended by java.io.OutputStreamWriter
          extended by org.globus.cog.karajan.workflow.nodes.restartLog.FlushableLockedFileWriter
All Implemented Interfaces:
Closeable, Flushable, Appendable

public class FlushableLockedFileWriter
extends OutputStreamWriter

A writer that will sync buffers to disks when flush() is called.


Constructor Summary
FlushableLockedFileWriter(File f, boolean append)
           
 
Method Summary
 void close()
           
 void flush()
           
 File getFile()
           
 boolean isLocked()
           
 
Methods inherited from class java.io.OutputStreamWriter
getEncoding, write, write, write
 
Methods inherited from class java.io.Writer
append, append, append, write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FlushableLockedFileWriter

public FlushableLockedFileWriter(File f,
                                 boolean append)
                          throws IOException
Throws:
IOException
Method Detail

flush

public void flush()
           throws IOException
Specified by:
flush in interface Flushable
Overrides:
flush in class OutputStreamWriter
Throws:
IOException

getFile

public File getFile()

close

public void close()
           throws IOException
Specified by:
close in interface Closeable
Overrides:
close in class OutputStreamWriter
Throws:
IOException

isLocked

public boolean isLocked()