Class StreamFeeder
java.lang.Object
java.lang.Thread
org.apache.maven.shared.utils.cli.AbstractStreamHandler
org.apache.maven.shared.utils.cli.StreamFeeder
- All Implemented Interfaces:
Runnable
Read from an InputStream and write the output to an OutputStream.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Thread
Thread.State, Thread.UncaughtExceptionHandler
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Throwable
private final AtomicReference<InputStream>
private final AtomicReference<OutputStream>
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
-
Constructor Summary
ConstructorsConstructorDescriptionStreamFeeder
(InputStream input, OutputStream output) Create a new StreamFeeder -
Method Summary
Methods inherited from class org.apache.maven.shared.utils.cli.AbstractStreamHandler
disable, isDisabled, isDone, setDone, waitUntilDone
Methods inherited from class java.lang.Thread
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yield
-
Field Details
-
input
-
output
-
exception
-
-
Constructor Details
-
StreamFeeder
StreamFeeder(InputStream input, OutputStream output) Create a new StreamFeeder- Parameters:
input
- Stream to read fromoutput
- Stream to write to
-
-
Method Details
-
run
public void run() -
close
public void close() -
getException
- Since:
- 3.2.0
-
feed
- Throws:
IOException
-