public class InternalInputStream extends SeekableInputStream
isClosed, isSourceClosed, resourceUsers| Constructor and Description |
|---|
InternalInputStream(File file) |
InternalInputStream(File file,
boolean isTempFile) |
InternalInputStream(File file,
int numOfFileUsers,
boolean isTempFile) |
InternalInputStream(RandomAccessFile stream,
long fromOffset,
long size,
IntReference numOfFileUsers,
String filePath,
boolean isTempFile) |
InternalInputStream(RandomAccessFile stream,
long fromOffset,
long size,
IntReference numOfFileUsers,
String filePath,
boolean isTempFile,
int bufferSize) |
InternalInputStream(String fileName) |
InternalInputStream(String fileName,
int numOfFileUsers) |
| Modifier and Type | Method and Description |
|---|---|
void |
closeResource()
Closes stream resource.
|
static InternalInputStream |
createConcatenated(byte[] alreadyRead,
InputStream stream)
Constructor writes into temp file passed buffer, then passed stream.
|
long |
getOffset()
Gets offset of current byte.
|
ASInputStream |
getStream(long startOffset,
long length)
Gets substream of this stream that starts at given offset and has given
length.
|
long |
getStreamLength()
Gets total length of stream.
|
int |
peek()
Gets next byte without reading it.
|
int |
read() |
int |
read(byte[] buffer,
int size) |
void |
reset() |
void |
seek(long offset)
Goes to a particular byte in stream.
|
int |
skip(int size) |
decrementResourceUsers, getSeekableStream, incrementResourceUsers, isEOF, readByte, seekFromCurrentPosition, seekFromEnd, unread, unreadclose, createStreamFromStreamavailable, mark, markSupported, read, read, skippublic InternalInputStream(File file) throws IOException
IOExceptionpublic InternalInputStream(File file, boolean isTempFile) throws IOException
IOExceptionpublic InternalInputStream(File file, int numOfFileUsers, boolean isTempFile) throws IOException
IOExceptionpublic InternalInputStream(String fileName) throws IOException
IOExceptionpublic InternalInputStream(String fileName, int numOfFileUsers) throws IOException
IOExceptionpublic InternalInputStream(RandomAccessFile stream, long fromOffset, long size, IntReference numOfFileUsers, String filePath, boolean isTempFile) throws IOException
IOExceptionpublic InternalInputStream(RandomAccessFile stream, long fromOffset, long size, IntReference numOfFileUsers, String filePath, boolean isTempFile, int bufferSize) throws IOException
IOExceptionpublic static InternalInputStream createConcatenated(byte[] alreadyRead, InputStream stream) throws IOException
alreadyRead - is byte array of data that was already read from the
beginning of stream.stream - is data left in stream.IOExceptionpublic int read()
throws IOException
read in class ASInputStreamIOExceptionpublic int read(byte[] buffer,
int size)
throws IOException
read in class ASInputStreamIOExceptionpublic int skip(int size)
throws IOException
skip in class ASInputStreamIOExceptionpublic void reset()
throws IOException
reset in class ASInputStreamIOExceptionpublic void seek(long offset)
throws IOException
SeekableInputStreamseek in class SeekableInputStreamoffset - is offset of a byte to go to.IOExceptionpublic int peek()
throws IOException
SeekableInputStreampeek in class SeekableInputStreamIOExceptionpublic long getOffset()
throws IOException
SeekableInputStreamgetOffset in class SeekableInputStreamIOExceptionpublic ASInputStream getStream(long startOffset, long length) throws IOException
SeekableInputStreamgetStream in class SeekableInputStreamstartOffset - is starting offset of substream.length - is length of substream.IOExceptionpublic void closeResource()
throws IOException
ASInputStreamcloseResource in class ASInputStreamIOExceptionpublic long getStreamLength()
throws IOException
SeekableInputStreamgetStreamLength in class SeekableInputStreamIOExceptionCopyright © 2015–2019 The veraPDF Consortium. All rights reserved.