Closeable, AutoCloseable, Readablepublic class CompoundReader extends Reader
| Modifier and Type | Field | Description |
|---|---|---|
protected Object |
finalLock |
|
protected boolean |
markSupported |
| Constructor | Description |
|---|---|
CompoundReader(Iterator<Reader> pReaders) |
Create a new compound reader.
|
| Modifier and Type | Method | Description |
|---|---|---|
void |
close() |
|
protected void |
ensureOpen() |
Check to make sure that the stream has not been closed
|
void |
mark(int pReadLimit) |
|
boolean |
markSupported() |
|
protected Reader |
nextReader() |
|
int |
read() |
|
int |
read(char[] pBuffer,
int pOffset,
int pLength) |
|
boolean |
ready() |
|
void |
reset() |
|
long |
skip(long pChars) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitread, read, transferToprotected final Object finalLock
protected final boolean markSupported
public CompoundReader(Iterator<Reader> pReaders)
pReaders - Iterator containting Readers,
providing the character stream.NullPointerException - if pReaders is null, or
any of the elements in the iterator is null.ClassCastException - if any element of the iterator is not a
java.io.Readerprotected final Reader nextReader()
protected final void ensureOpen()
throws IOException
IOException - if the stream is closedpublic void close()
throws IOException
close in interface AutoCloseableclose in interface Closeableclose in class ReaderIOExceptionpublic void mark(int pReadLimit)
throws IOException
mark in class ReaderIOExceptionpublic void reset()
throws IOException
reset in class ReaderIOExceptionpublic boolean markSupported()
markSupported in class Readerpublic int read()
throws IOException
read in class ReaderIOExceptionpublic int read(char[] pBuffer,
int pOffset,
int pLength)
throws IOException
read in class ReaderIOExceptionpublic boolean ready()
throws IOException
ready in class ReaderIOExceptionpublic long skip(long pChars)
throws IOException
skip in class ReaderIOExceptionCopyright © 2018. All rights reserved.