public class JoinedInputStream
extends java.io.InputStream
InputStream's into one.
Reading from an instance of JoinedInputStream will
read each underlying InputStream until it is
depleted and then continue with the next one.
Depleted InputStream's will be closed as soon
as possible.
| Constructor and Description |
|---|
JoinedInputStream() |
| Modifier and Type | Method and Description |
|---|---|
JoinedInputStream |
add(java.io.InputStream in)
Add another
InputStream. |
void |
close() |
int |
read() |
int |
read(byte[] b,
int off,
int len) |
public JoinedInputStream add(java.io.InputStream in)
InputStream.
It is allowed to add more InputStream's
even after reading has started.
It is illegal to add more streams after the joined stream has been closed.
public int read()
throws java.io.IOException
read in class java.io.InputStreamjava.io.IOExceptionpublic int read(byte[] b,
int off,
int len)
throws java.io.IOException
read in class java.io.InputStreamjava.io.IOExceptionpublic void close()
throws java.io.IOException
close in interface java.io.Closeableclose in interface java.lang.AutoCloseableclose in class java.io.InputStreamjava.io.IOExceptionCopyright © 2008-2013. All Rights Reserved.