public static class OfflineSorter.ByteSequencesReader extends Object implements Closeable
OfflineSorter.ByteSequencesWriter
.Modifier and Type | Field and Description |
---|---|
protected long |
end |
protected ChecksumIndexInput |
in |
protected String |
name |
Constructor and Description |
---|
ByteSequencesReader(ChecksumIndexInput in,
String name)
Constructs a ByteSequencesReader from the provided IndexInput
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes the provided
IndexInput . |
boolean |
read(BytesRefBuilder ref)
Reads the next entry into the provided
BytesRef . |
protected final String name
protected final ChecksumIndexInput in
protected final long end
public ByteSequencesReader(ChecksumIndexInput in, String name)
public boolean read(BytesRefBuilder ref) throws IOException
BytesRef
. The internal
storage is resized if needed.false
if EOF occurred when trying to read
the header of the next sequence. Returns true
otherwise.EOFException
- if the file ends before the full sequence is read.IOException
public void close() throws IOException
IndexInput
.close
in interface Closeable
close
in interface AutoCloseable
IOException
Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.