protected class FileContents.RecReader
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected java.nio.ByteBuffer |
buffer |
protected long |
currentBlockOffset |
protected java.nio.channels.FileChannel |
fileChannel |
protected long |
fSize |
protected byte[] |
line
Get a record from file.
|
protected java.nio.MappedByteBuffer |
mappedByteBuffer |
protected java.io.RandomAccessFile |
raf |
Constructor and Description |
---|
FileContents.RecReader(java.io.File file) |
protected long fSize
protected java.nio.MappedByteBuffer mappedByteBuffer
protected java.nio.ByteBuffer buffer
protected long currentBlockOffset
protected java.io.RandomAccessFile raf
protected java.nio.channels.FileChannel fileChannel
protected byte[] line
public FileContents.RecReader(java.io.File file) throws java.io.FileNotFoundException
java.io.FileNotFoundException
public void close() throws java.io.IOException
java.io.IOException
protected int seek(long pos) throws java.io.IOException
pos
- the new position.java.io.IOException
public java.lang.String getRecord(int pos) throws java.io.IOException
java.io.IOException
public java.lang.String getRecord(long pos, long noLines) throws java.io.IOException
java.io.IOException