|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.terrier.structures.indexing.singlepass.RunIterator
public abstract class RunIterator
An abstract base class which allows PostingInRuns to be iterated over. Implementations are typically more generic versions of RunReader from Terrier 2.0 and 2.1.
| Field Summary | |
|---|---|
protected int |
flushNo
Run/Flush that the current posting came from |
protected int |
numberOfFields
|
protected PostingInRun |
posting
current posting |
protected java.lang.Class<? extends PostingInRun> |
postingClass
class that new postings are derived from |
| Constructor Summary | |
|---|---|
protected |
RunIterator(java.lang.Class<? extends PostingInRun> _postingClass,
int _runNo,
int _numberOfFields)
create a new instance of this class. |
| Method Summary | |
|---|---|
void |
close()
close this RunIterator |
protected void |
createPosting()
Create a new posting |
PostingInRun |
current()
returns the current posting |
int |
getRunNo()
Get the run/flush number that the current posting came from |
abstract boolean |
hasNext()
iterator implementation |
abstract PostingInRun |
next()
iterator implementation |
void |
remove()
unsupported iterator method |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.lang.Class<? extends PostingInRun> postingClass
protected PostingInRun posting
protected int flushNo
protected int numberOfFields
| Constructor Detail |
|---|
protected RunIterator(java.lang.Class<? extends PostingInRun> _postingClass,
int _runNo,
int _numberOfFields)
_postingClass - Class of the PostingInRun type that postings in this run have_runNo - The run number currently being processed| Method Detail |
|---|
protected void createPosting()
throws java.lang.Exception
java.lang.Exceptionpublic int getRunNo()
public abstract boolean hasNext()
hasNext in interface java.util.Iterator<PostingInRun>public abstract PostingInRun next()
next in interface java.util.Iterator<PostingInRun>public PostingInRun current()
public void remove()
remove in interface java.util.Iterator<PostingInRun>public void close()
close in interface java.io.Closeable
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||