public class ContentLengthInputStream
extends java.io.InputStream
InputStream
. Provides possibility to return defined stream length by
available()
method.Constructor and Description |
---|
ContentLengthInputStream(java.io.InputStream stream,
int length) |
public ContentLengthInputStream(java.io.InputStream stream, int length)
public int available()
available
in class java.io.InputStream
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.InputStream
java.io.IOException
public void mark(int readLimit)
mark
in class java.io.InputStream
public int read() throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public int read(byte[] buffer) throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public int read(byte[] buffer, int byteOffset, int byteCount) throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public void reset() throws java.io.IOException
reset
in class java.io.InputStream
java.io.IOException
public long skip(long byteCount) throws java.io.IOException
skip
in class java.io.InputStream
java.io.IOException
public boolean markSupported()
markSupported
in class java.io.InputStream