public class FragmentInputStream
extends java.io.InputStream
Constructor and Description |
---|
FragmentInputStream(java.util.List<long[]> fragments,
java.io.RandomAccessFile raf) |
FragmentInputStream(java.util.List<long[]> fragments,
java.io.RandomAccessFile raf,
int bufSize) |
Modifier and Type | Method and Description |
---|---|
int |
read()
Returns the next byte from the stream, buffering each fragment
in turn until the last fragment is exhausted.
|
public FragmentInputStream(java.util.List<long[]> fragments, java.io.RandomAccessFile raf)
fragments
- List of fragment entries.
Each fragment entry is an array of two longs,
with fragment[0] being the length and
fragment[1] the offset.public FragmentInputStream(java.util.List<long[]> fragments, java.io.RandomAccessFile raf, int bufSize)
public int read() throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException