public class JoinedInputStream extends 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(InputStream in)
Add another
InputStream. |
void |
close() |
int |
read() |
int |
read(byte[] b,
int off,
int len) |
available, mark, markSupported, read, reset, skippublic JoinedInputStream add(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 IOException
read in class InputStreamIOExceptionpublic int read(byte[] b,
int off,
int len)
throws IOException
read in class InputStreamIOExceptionpublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class InputStreamIOExceptionCopyright © 2008–2015. All rights reserved.