public class EOFOnMatchInputStream extends PushbackInputStream implements ReadCounter
buf, posin| Constructor and Description |
|---|
EOFOnMatchInputStream(InputStream in,
byte[] match)
Non-counter mode.
|
EOFOnMatchInputStream(InputStream in,
ReadCounter ctr,
byte[] match)
Counter mode.
|
| Modifier and Type | Method and Description |
|---|---|
long |
getRead()
If constructed with a counter, returns the count
(not necessarily starting at 0) minus the buffered/matched count.
|
int |
read()
Debug only.
|
int |
read(byte[] buf,
int off,
int len) |
long |
skip(long n) |
boolean |
wasFound() |
available, close, mark, markSupported, reset, unread, unread, unreadreadpublic EOFOnMatchInputStream(InputStream in, byte[] match)
match - will be copiedpublic EOFOnMatchInputStream(InputStream in, ReadCounter ctr, byte[] match)
match - will be copiedpublic long getRead()
getRead in interface ReadCounterpublic int read()
throws IOException
read in class PushbackInputStreamIOExceptionpublic int read(byte[] buf,
int off,
int len)
throws IOException
read in class PushbackInputStreamIOExceptionpublic long skip(long n)
throws IOException
skip in class PushbackInputStreamIOExceptionpublic boolean wasFound()