Interface LogCommandOutput
- All Superinterfaces:
Callable<CommandOutput>,CommandOutput
- All Known Implementing Classes:
AbstractLogCommandOutput,AbstractLogCommandOutput.DebugLogCommandOutput,AbstractLogCommandOutput.ErrorLogCommandOutput,AbstractLogCommandOutput.InfoLogCommandOutput,AbstractLogCommandOutput.TraceLogCommandOutput
Pipes the read data from the output of the command to a logger.
- Since:
- 3.1
- Author:
- Erwin Mueller, erwin.mueller@deventm.org
-
Method Summary
Modifier and TypeMethodDescriptionReturns the command for the logging message.Returns the command line for the logging message.getInput()Returns the stream that is connected to output of the executed command.org.slf4j.LoggerReturns the logger that is filled with the piped to the output of the command.Returns the message string.voidsetBufferSize(int size) Sets the buffer size.voidsetLogger(org.slf4j.Logger logger) Sets the logger that is filled with the piped to the output of the command.voidsetMessage(String message) Sets the message string.Methods inherited from interface com.anrisoftware.globalpom.exec.external.core.CommandOutput
call, clone, setInput
-
Method Details
-
getInput
InputStream getInput()Returns the stream that is connected to output of the executed command.- Returns:
- the
InputStream.
-
setBufferSize
void setBufferSize(int size) Sets the buffer size.- Parameters:
size- the size in bytes.
-
setLogger
void setLogger(org.slf4j.Logger logger) Sets the logger that is filled with the piped to the output of the command.- Parameters:
logger- theLogger.
-
getLogger
org.slf4j.Logger getLogger()Returns the logger that is filled with the piped to the output of the command.- Returns:
- the
Logger.
-
getCommandLine
CommandLine getCommandLine()Returns the command line for the logging message.- Returns:
- the
CommandLine.
-
getCommand
String getCommand()Returns the command for the logging message.- Returns:
- the
Stringcommand.
-
setMessage
Sets the message string.- Parameters:
message- theStringmessage.
-
getMessage
String getMessage()Returns the message string.- Returns:
- the
Stringmessage.
-