public static class SetFile.Reader extends MapFile.Reader
MapFile.Reader.Option| Constructor and Description |
|---|
Reader(FileSystem fs,
String dirName,
Configuration conf)
Construct a set reader for the named set.
|
Reader(FileSystem fs,
String dirName,
WritableComparator comparator,
Configuration conf)
Construct a set reader for the named set using the named comparator.
|
| Modifier and Type | Method and Description |
|---|---|
WritableComparable |
get(WritableComparable key)
Read the matching key from a set into
key. |
boolean |
next(WritableComparable key)
Read the next key in a set into
key. |
boolean |
seek(WritableComparable key)
Positions the reader at the named key, or if none such exists, at the
first entry after the named key.
|
close, comparator, createDataFileReader, finalKey, get, getClosest, getClosest, getKeyClass, getValueClass, midKey, next, open, resetpublic Reader(FileSystem fs, String dirName, Configuration conf) throws IOException
fs - input FileSystem.dirName - input dirName.conf - input Configuration.IOException - raised on errors performing I/O.public Reader(FileSystem fs, String dirName, WritableComparator comparator, Configuration conf) throws IOException
fs - input FileSystem.dirName - input dirName.comparator - input comparator.conf - input Configuration.IOException - raised on errors performing I/O.public boolean seek(WritableComparable key) throws IOException
MapFile.Readerseek in class MapFile.Readerkey - key.IOException - raised on errors performing I/O.public boolean next(WritableComparable key) throws IOException
key.key - input key.IOException - raised on errors performing I/O.public WritableComparable get(WritableComparable key) throws IOException
key.key - input key.key, or null if no match exists.IOException - raised on errors performing I/O.Copyright © 2008–2025 Apache Software Foundation. All rights reserved.