@InterfaceAudience.Private @InterfaceStability.Evolving public class ExactSizeInputStream extends FilterInputStream
in
Constructor and Description |
---|
ExactSizeInputStream(InputStream in,
int numBytes)
Construct an input stream that will read no more than
'numBytes' bytes.
|
Modifier and Type | Method and Description |
---|---|
int |
available() |
void |
mark(int readlimit) |
boolean |
markSupported() |
int |
read() |
int |
read(byte[] b,
int off,
int len) |
long |
skip(long n) |
close, read, reset
public ExactSizeInputStream(InputStream in, int numBytes)
in
- the inputstream to wrapnumBytes
- the number of bytes to readpublic int available() throws IOException
available
in class FilterInputStream
IOException
public int read() throws IOException
read
in class FilterInputStream
IOException
public int read(byte[] b, int off, int len) throws IOException
read
in class FilterInputStream
IOException
public long skip(long n) throws IOException
skip
in class FilterInputStream
IOException
public boolean markSupported()
markSupported
in class FilterInputStream
public void mark(int readlimit)
mark
in class FilterInputStream
Copyright © 2013 Apache Software Foundation. All rights reserved.