|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectnet.nutch.io.MapFile.Reader
Provide access to an existing map.
| Constructor Summary | |
MapFile.Reader(String dirName)
Construct a map reader for the named map. |
|
MapFile.Reader(String dirName,
WritableComparator comparator)
Construct a map reader for the named map using the named comparator. |
|
| Method Summary | |
void |
close()
Close the map. |
Writable |
get(WritableComparable key,
Writable val)
Return the value for the named key, or null if none exists. |
Class |
getKeyClass()
Returns the class of keys in this file. |
Class |
getValueClass()
Returns the class of values in this file. |
boolean |
next(WritableComparable key,
Writable val)
Read the next key/value pair in the map into key and
val. |
void |
reset()
Re-positions the reader before its first 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. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public MapFile.Reader(String dirName)
throws IOException
public MapFile.Reader(String dirName,
WritableComparator comparator)
throws IOException
| Method Detail |
public Class getKeyClass()
public Class getValueClass()
public void reset()
throws IOException
IOException
public boolean seek(WritableComparable key)
throws IOException
IOException
public boolean next(WritableComparable key,
Writable val)
throws IOException
key and
val. Returns true if such a pair exists and false when at
the end of the map
IOException
public Writable get(WritableComparable key,
Writable val)
throws IOException
IOException
public void close()
throws IOException
IOException
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||