public class ConsoleInterface
extends java.lang.Thread
Modifier and Type | Field and Description |
---|---|
private java.util.concurrent.Semaphore |
dataIsRead |
private ConcurrentLog |
log |
private java.util.List<java.lang.String> |
output |
private java.io.InputStream |
stream |
Modifier | Constructor and Description |
---|---|
private |
ConsoleInterface(java.io.InputStream stream,
ConcurrentLog log) |
Modifier and Type | Method and Description |
---|---|
private static java.util.List<java.lang.String> |
getConsoleOutput(java.util.List<java.lang.String> processArgs,
ConcurrentLog log)
simple interface
|
static java.lang.String |
getLastLineConsoleOutput(java.util.List<java.lang.String> processArgs,
ConcurrentLog log) |
java.util.List<java.lang.String> |
getOutput()
waits until the stream is read and returns all data
|
void |
run() |
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
private final java.io.InputStream stream
private final java.util.List<java.lang.String> output
private final java.util.concurrent.Semaphore dataIsRead
private final ConcurrentLog log
private ConsoleInterface(java.io.InputStream stream, ConcurrentLog log)
public void run()
run
in interface java.lang.Runnable
run
in class java.lang.Thread
public java.util.List<java.lang.String> getOutput()
private static java.util.List<java.lang.String> getConsoleOutput(java.util.List<java.lang.String> processArgs, ConcurrentLog log) throws java.io.IOException
java.io.IOException
public static java.lang.String getLastLineConsoleOutput(java.util.List<java.lang.String> processArgs, ConcurrentLog log) throws java.io.IOException
java.io.IOException