public class LargeFileSubstitutionHandler extends FileSubstitutionHandler
Reader and Writer for the String substitution file.
Implementation is useful for large files which cann't be read entirely in a
memory or need a substantial amount of memory.
To perform substitution it take helps of temporary file to write output, after substitution, temporary file renamed to input file.
_inputFile, _logger, _reader, _strings, _writer| Constructor and Description |
|---|
LargeFileSubstitutionHandler(File file) |
| Modifier and Type | Method and Description |
|---|---|
void |
finish()
Called at the completion of the substitution process to perform
post operation.
|
Reader |
getReader()
Gets the character stream from the input.
|
Writer |
getWriter()
Gets the
Writer object to write the character stream in to
the output. |
getNamepublic LargeFileSubstitutionHandler(File file) throws FileNotFoundException
FileNotFoundExceptionpublic Reader getReader()
SubstitutableImplementation note: It is a good idea for the input stream to be buffered.
public Writer getWriter()
SubstitutableWriter object to write the character stream in to
the output.
Implementation note: It is a good idea for the output stream to be buffered.
public void finish()
Substitutablefinish in interface Substitutablefinish in class FileSubstitutionHandlerCopyright © 2018 Eclipse Foundation. All rights reserved.