public class ByteArrayFileInputStream
extends java.io.InputStream
Modifier and Type | Field and Description |
---|---|
protected byte[] |
data |
protected boolean |
deleteOnClose |
protected java.io.File |
file |
protected java.io.FileInputStream |
fileInputStream |
protected long |
fileSize |
protected int |
index |
protected int |
markIndex |
protected int |
threshold |
Constructor and Description |
---|
ByteArrayFileInputStream(java.io.File file,
int threshold) |
ByteArrayFileInputStream(java.io.File file,
int threshold,
boolean deleteOnClose) |
Modifier and Type | Method and Description |
---|---|
int |
available() |
void |
close() |
java.io.File |
getFile() |
protected void |
initData() |
protected void |
initFileInputStream() |
void |
mark(int readLimit) |
boolean |
markSupported() |
int |
read() |
int |
read(byte[] bytes) |
int |
read(byte[] bytes,
int offset,
int length) |
void |
reset() |
long |
skip(long skip) |
protected byte[] data
protected boolean deleteOnClose
protected java.io.File file
protected java.io.FileInputStream fileInputStream
protected long fileSize
protected int index
protected int markIndex
protected int threshold
public ByteArrayFileInputStream(java.io.File file, int threshold)
public ByteArrayFileInputStream(java.io.File file, int threshold, boolean deleteOnClose)
public int available() throws java.io.IOException
available
in class java.io.InputStream
java.io.IOException
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 java.io.File getFile()
public void mark(int readLimit)
mark
in class java.io.InputStream
public boolean markSupported()
markSupported
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[] bytes) throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public int read(byte[] bytes, int offset, int length) 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 skip) throws java.io.IOException
skip
in class java.io.InputStream
java.io.IOException
protected void initData() throws java.io.IOException
java.io.IOException
protected void initFileInputStream() throws java.io.IOException
java.io.IOException