public class FileProgressListener extends StreamProgressListener
File is only opened when benchmarking starts, if the file exists then it may either overwrite the existing file or append to it depending on the constructor arguments used. Default behaviour is to overwrite.
Constructor and Description |
---|
FileProgressListener(String filename)
Creates a new File Progress Listener which will overwrite a file of the given name
|
FileProgressListener(String filename,
boolean append)
Creates a new File Progress Listener which may append to the file of the given name depending on the
append parameter |
Modifier and Type | Method and Description |
---|---|
protected OutputStream |
openStream()
Opens the File as an Output Stream returning null if the file cannot be used for output
|
afterOperation, afterOperationMix, beforeOperation, beforeOperationMix, finish, hasSwitchedThreads, progress, setForceThreadedOutput, start, updateThread
public FileProgressListener(String filename, boolean append)
append
parameterfilename
- Filenameappend
- Whether to append to the file, if false file will be overwritten if it existspublic FileProgressListener(String filename)
filename
- Filenameprotected OutputStream openStream()
openStream
in class StreamProgressListener
Copyright © 2016. All rights reserved.