org.terrier.structures
Class FSOMapFileLexicon.MapFileLexiconIterator

java.lang.Object
  extended by org.terrier.structures.FSOMapFileLexicon.MapFileLexiconIterator
All Implemented Interfaces:
Closeable, Iterator<Map.Entry<String,LexiconEntry>>
Enclosing class:
FSOMapFileLexicon

public static class FSOMapFileLexicon.MapFileLexiconIterator
extends Object
implements Iterator<Map.Entry<String,LexiconEntry>>, Closeable

An iterator over the lexicon


Field Summary
protected  Iterator<Map.Entry<org.apache.hadoop.io.Text,LexiconEntry>> parent
           
 
Constructor Summary
FSOMapFileLexicon.MapFileLexiconIterator(Iterator<Map.Entry<org.apache.hadoop.io.Text,LexiconEntry>> _parent)
          Construct an instance of the class with
FSOMapFileLexicon.MapFileLexiconIterator(String filename, FixedSizeWriteableFactory<org.apache.hadoop.io.Text> keyFactory, FixedSizeWriteableFactory<LexiconEntry> valueFactory)
          Construct an instance of the class with
FSOMapFileLexicon.MapFileLexiconIterator(String structureName, Index index)
          Construct an instance of the class with
FSOMapFileLexicon.MapFileLexiconIterator(String structureName, String path, String prefix, FixedSizeWriteableFactory<org.apache.hadoop.io.Text> keyFactory, FixedSizeWriteableFactory<LexiconEntry> valueFactory)
          Construct an instance of the class with
 
Method Summary
 void close()
          
 boolean hasNext()
          
 Map.Entry<String,LexiconEntry> next()
          
 void remove()
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

parent

protected Iterator<Map.Entry<org.apache.hadoop.io.Text,LexiconEntry>> parent
Constructor Detail

FSOMapFileLexicon.MapFileLexiconIterator

public FSOMapFileLexicon.MapFileLexiconIterator(String structureName,
                                                Index index)
                                         throws IOException
Construct an instance of the class with

Parameters:
structureName -
index -
Throws:
IOException

FSOMapFileLexicon.MapFileLexiconIterator

public FSOMapFileLexicon.MapFileLexiconIterator(String structureName,
                                                String path,
                                                String prefix,
                                                FixedSizeWriteableFactory<org.apache.hadoop.io.Text> keyFactory,
                                                FixedSizeWriteableFactory<LexiconEntry> valueFactory)
                                         throws IOException
Construct an instance of the class with

Parameters:
structureName -
path -
prefix -
keyFactory -
valueFactory -
Throws:
IOException

FSOMapFileLexicon.MapFileLexiconIterator

public FSOMapFileLexicon.MapFileLexiconIterator(String filename,
                                                FixedSizeWriteableFactory<org.apache.hadoop.io.Text> keyFactory,
                                                FixedSizeWriteableFactory<LexiconEntry> valueFactory)
                                         throws IOException
Construct an instance of the class with

Parameters:
filename -
keyFactory -
valueFactory -
Throws:
IOException

FSOMapFileLexicon.MapFileLexiconIterator

public FSOMapFileLexicon.MapFileLexiconIterator(Iterator<Map.Entry<org.apache.hadoop.io.Text,LexiconEntry>> _parent)
Construct an instance of the class with

Parameters:
_parent -
Method Detail

hasNext

public boolean hasNext()

Specified by:
hasNext in interface Iterator<Map.Entry<String,LexiconEntry>>

next

public Map.Entry<String,LexiconEntry> next()

Specified by:
next in interface Iterator<Map.Entry<String,LexiconEntry>>

remove

public void remove()

Specified by:
remove in interface Iterator<Map.Entry<String,LexiconEntry>>

close

public void close()
           throws IOException

Specified by:
close in interface Closeable
Throws:
IOException


Terrier 3.6. Copyright © 2004-2011 University of Glasgow