public class PreservingFileWriter
extends java.io.FileWriter
| Modifier and Type | Field and Description |
|---|---|
protected java.io.File |
target_file |
protected java.io.File |
tmp_file |
| Constructor and Description |
|---|
PreservingFileWriter(java.lang.String file) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the file and see if the actual target is different
if so the target file is overwritten by the copy.
|
protected java.io.File target_file
protected java.io.File tmp_file
public PreservingFileWriter(java.lang.String file)
throws java.io.IOException
java.io.IOExceptionpublic void close()
throws java.io.IOException
close in interface java.io.Closeableclose in interface java.lang.AutoCloseableclose in class java.io.OutputStreamWriterjava.io.IOException