public class BoundedInputStream
extends java.io.InputStream
Constructor and Description |
---|
BoundedInputStream(java.io.InputStream in,
long size)
Creates the stream that will at most read the given amount of
bytes from the given stream.
|
Modifier and Type | Method and Description |
---|---|
void |
close() |
int |
read() |
int |
read(byte[] b,
int off,
int len) |
public BoundedInputStream(java.io.InputStream in, long size)
in
- the stream to read fromsize
- the maximum amount of bytes to readpublic int read() throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public int read(byte[] b, int off, int len) throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public void close()
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.InputStream
"Copyright © 2010 - 2020 Adobe Systems Incorporated. All Rights Reserved"