public final class CountingInputStream extends InputStream
InputStream implementation which just consume the the wrapped InputStream and count
the lines which are contained within the wrapped stream| Constructor and Description |
|---|
CountingInputStream(InputStream in) |
| Modifier and Type | Method and Description |
|---|---|
int |
getLineCount()
Return the line count
|
int |
getOctetCount()
Return the octet count
|
int |
read() |
void |
readAll()
Reads - and discards - the rest of the stream
|
available, close, mark, markSupported, read, read, reset, skippublic CountingInputStream(InputStream in)
public int read()
throws IOException
read in class InputStreamIOExceptionInputStream.read()public int getLineCount()
public int getOctetCount()
public void readAll()
throws IOException
IOExceptionCopyright © 2010-2012 The Apache Software Foundation. All Rights Reserved.