com.sun.labs.minion.indexer.dictionary
Class DiskDictionary.LightDiskDictionaryIterator

java.lang.Object
  extended by com.sun.labs.minion.indexer.dictionary.DiskDictionary.LightDiskDictionaryIterator
All Implemented Interfaces:
LightIterator
Enclosing class:
DiskDictionary

public class DiskDictionary.LightDiskDictionaryIterator
extends java.lang.Object
implements LightIterator

A lightweight iterator for this dictionary.


Field Summary
protected  DiskDictionary.LookupState lus
           
protected  int posn
          The position in the dictionary.
protected  java.lang.Object prevName
          The name of the previous entry.
 
Constructor Summary
DiskDictionary.LightDiskDictionaryIterator()
           
 
Method Summary
 QueryEntry getEntry()
          Gets the entire current entry.
 int getID()
          Gets the ID of the current entry.
 int getN()
          Gets the number of postings associated with the entry that the iterator is currently pointing at.
 java.lang.Object getName()
          Gets the name of the entry that the iterator is currently pointing at.
 boolean next()
          Advances the iterator to the next entry in the dictionary.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

posn

protected int posn
The position in the dictionary.


lus

protected DiskDictionary.LookupState lus

prevName

protected java.lang.Object prevName
The name of the previous entry.

Constructor Detail

DiskDictionary.LightDiskDictionaryIterator

public DiskDictionary.LightDiskDictionaryIterator()
Method Detail

next

public boolean next()
Description copied from interface: LightIterator
Advances the iterator to the next entry in the dictionary.

Specified by:
next in interface LightIterator
Returns:
true if there is such an entry, false otherwise.

getName

public java.lang.Object getName()
Description copied from interface: LightIterator
Gets the name of the entry that the iterator is currently pointing at.

Specified by:
getName in interface LightIterator
Returns:
the name of the current entry.

getN

public int getN()
Description copied from interface: LightIterator
Gets the number of postings associated with the entry that the iterator is currently pointing at.

Specified by:
getN in interface LightIterator
Returns:
the number of postings associated with the current entry.

getEntry

public QueryEntry getEntry()
Description copied from interface: LightIterator
Gets the entire current entry.

Specified by:
getEntry in interface LightIterator
Returns:
the current entry.

getID

public int getID()
Description copied from interface: LightIterator
Gets the ID of the current entry.

Specified by:
getID in interface LightIterator