public final class MergedReader extends Reader
Reader implementation that is used to "unwind" some
data previously read from a Reader; so that as long as some of
that data remains, it's returned; but as long as it's read, we'll
just use data from the underlying original Reader.
This is similar to PushbackReader, but with this class
there's only one implicit pushback, when instance is constructed; not
general pushback buffer and methods to use it.| Constructor and Description |
|---|
MergedReader(ReaderConfig cfg,
Reader in,
char[] buf,
int start,
int end) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
mark(int readlimit) |
boolean |
markSupported() |
int |
read() |
int |
read(char[] cbuf) |
int |
read(char[] cbuf,
int off,
int len) |
boolean |
ready() |
void |
reset() |
long |
skip(long n) |
public MergedReader(ReaderConfig cfg, Reader in, char[] buf, int start, int end)
public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class ReaderIOExceptionpublic void mark(int readlimit)
throws IOException
mark in class ReaderIOExceptionpublic boolean markSupported()
markSupported in class Readerpublic int read()
throws IOException
read in class ReaderIOExceptionpublic int read(char[] cbuf)
throws IOException
read in class ReaderIOExceptionpublic int read(char[] cbuf,
int off,
int len)
throws IOException
read in class ReaderIOExceptionpublic boolean ready()
throws IOException
ready in class ReaderIOExceptionpublic void reset()
throws IOException
reset in class ReaderIOExceptionpublic long skip(long n)
throws IOException
skip in class ReaderIOExceptionCopyright © 2022 FasterXML. All rights reserved.