public abstract class UpdatableFile
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
protected java.nio.file.Path |
myFile
The actual file object.
|
| Constructor and Description |
|---|
UpdatableFile(java.nio.file.Path file) |
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
createEmpty(java.io.Writer out)
Create an empty file.
|
protected void |
update(java.io.StringWriter content)
Replace the actual file with
content. |
public UpdatableFile(java.nio.file.Path file)
throws PackageException
PackageExceptionprotected abstract void createEmpty(java.io.Writer out)
throws java.io.IOException
out - the writer for the file.java.io.IOException - if an error occurs whilst writing the empty file.protected void update(java.io.StringWriter content)
throws PackageException
content.content - the new contentPackageException - if an error occursCopyright © 2015-2020 EXPath. All Rights Reserved