wt.tools.generation.language
Class JavaObject

java.lang.Object
  extended byjava.io.Writer
      extended bywt.util.OutputFile
          extended bywt.tools.generation.language.MergableWriterFile
              extended bywt.tools.generation.language.ClassWriterFile
                  extended bywt.tools.generation.language.JavaObject

public class JavaObject
extends ClassWriterFile


Field Summary
protected  ObjectOutputStream objectOutput
           
 
Fields inherited from class wt.tools.generation.language.MergableWriterFile
outputEntities
 
Fields inherited from class wt.util.OutputFile
allInstances, backup, encoding, fileName, keepBackup, mergeFileName, readOnlyWarning, removeMergeFile, writeMode, writer
 
Fields inherited from class java.io.Writer
lock
 
Constructor Summary
protected JavaObject()
           
 
Method Summary
 void close()
          Close the OutputFile.
 boolean open()
          Opens the OutputFile, so that print and println can be performed.
 void write()
           
 
Methods inherited from class wt.tools.generation.language.MergableWriterFile
addOutput, get, mergePreparation, writeFooter, writeHeader
 
Methods inherited from class wt.util.OutputFile
backUpName, close, createBackupFile, ensureDirectoryExists, flush, get, getAllFiles, getFileName, getMergeFileName, getWriteMode, getWriter, print, println, restoreBackupFile, setEncoding, setFileName, setMergeFileName, setRemoveMergeFile, setWriteMode, toString, write
 
Methods inherited from class java.io.Writer
write, write, write, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

objectOutput

protected ObjectOutputStream objectOutput
Constructor Detail

JavaObject

protected JavaObject()
Method Detail

close

public void close()
Description copied from class: OutputFile
Close the OutputFile. If applicable, will delete a temporary backup file.

Overrides:
close in class OutputFile

open

public boolean open()
Description copied from class: OutputFile
Opens the OutputFile, so that print and println can be performed. The WriteMode is considered to deterimine the exact actions to take.
   WriteMode.BACKUP    = Create a backup of any existing file, before re-writing it.
   WriteMode.MERGE     = Merge into an existing file.
   WriteMode.ORIGINAL  = Only open the file, if it doesn't already exist.
   WriteMode.OVERWRITE = Clobber an existing file.
 
*Assumes source mergeFile and target output file will be in the same path.

Overrides:
open in class OutputFile
Returns:
true if it succeeds, otherwise return false
See Also:
WriteMode

write

public void write()
Overrides:
write in class MergableWriterFile