public class BundleResourceStream
extends java.io.InputStream
限定符和类型 | 字段和说明 |
---|---|
protected long |
contentLen |
protected java.io.InputStream |
wis |
构造器和说明 |
---|
BundleResourceStream(java.io.InputStream is,
long length)
BundleResourceStream
|
限定符和类型 | 方法和说明 |
---|---|
int |
available()
Return the number of bytes available for immediate read
|
void |
close()
Close input stream
|
long |
getContentLength()
Get length of resource stream.
|
void |
mark(int readlimit)
Mark current position in input stream
|
boolean |
markSupported()
Check it mark/reset is supported.
|
int |
read()
Read a byte from the input stream.
|
int |
read(byte[] dest)
Read bytes from the input stream.
|
int |
read(byte[] dest,
int off,
int len)
Read a specified number of bytes from the input stream.
|
void |
reset()
Return to marked position.
|
long |
skip(long len)
Skip over (and discard) a specified number of bytes in this input
stream.
|
public BundleResourceStream(java.io.InputStream is, long length)
is
- Underlying input stream.public long getContentLength()
public int read() throws java.io.IOException
read
在类中 java.io.InputStream
java.io.IOException
public int read(byte[] dest) throws java.io.IOException
read
在类中 java.io.InputStream
dest
- Byte array to read intojava.io.IOException
public int read(byte[] dest, int off, int len) throws java.io.IOException
read
在类中 java.io.InputStream
dest
- Byte array to read intooff
- Starting offset into the byte arraylen
- Maximum number of bytes to readjava.io.IOException
public long skip(long len) throws java.io.IOException
skip
在类中 java.io.InputStream
len
- Number of bytes to be skippedjava.io.IOException
public int available() throws java.io.IOException
available
在类中 java.io.InputStream
java.io.IOException
public void close() throws java.io.IOException
close
在接口中 java.io.Closeable
close
在接口中 java.lang.AutoCloseable
close
在类中 java.io.InputStream
java.io.IOException
public void mark(int readlimit)
mark
在类中 java.io.InputStream
readlimit
- Maximum of bytes when can save.public void reset() throws java.io.IOException
reset
在类中 java.io.InputStream
java.io.IOException
public boolean markSupported()
markSupported
在类中 java.io.InputStream