public class FileCommandOutput extends CommandOutput
Constructor and Description |
---|
FileCommandOutput(File file,
boolean appendToOutput) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Close the output;
|
void |
print(String value)
Print out value to output without line break
|
void |
printError(Throwable e) |
void |
printMessage(String message)
Print message to non-standard console for human to read.
|
println
public FileCommandOutput(File file, boolean appendToOutput) throws IOException
file
- where the result is written to.appendToOutput
- whether to write to output.IOException
- allows IO error.public void close()
CommandOutput
close
in class CommandOutput
public void print(String value)
CommandOutput
print
in class CommandOutput
value
- Value to print outpublic void printError(Throwable e)
printError
in class CommandOutput
e
- Error to print outpublic void printMessage(String message)
CommandOutput
printMessage
in class CommandOutput
message
- Message to print out.Copyright © 2008–2018. All rights reserved.