|
Terrier IR Platform 1.1.1 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectuk.ac.gla.terrier.structures.indexing.DocumentIndexBuilder
public class DocumentIndexBuilder
A builder for the document index.
| Constructor Summary | |
|---|---|
DocumentIndexBuilder()
A default constructor for the class. |
|
DocumentIndexBuilder(java.lang.String filename)
A constructor of a document index from a given filename. |
|
DocumentIndexBuilder(java.lang.String path,
java.lang.String prefix)
Constructor using index path and prefix. |
|
| Method Summary | |
|---|---|
void |
addEntryToBuffer(java.lang.String docno,
int docLength,
FilePosition directIndexOffset)
Adds to the index a new entry, giving to it the next available document id. |
void |
close()
Closes the random access file. |
void |
finishedCollections()
Closes the underlying file after finished processing the collections. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DocumentIndexBuilder()
public DocumentIndexBuilder(java.lang.String path,
java.lang.String prefix)
path - path to the indexprefix - filename prefix of the indexpublic DocumentIndexBuilder(java.lang.String filename)
filename - String the filename of the document index,
with an extension| Method Detail |
|---|
public void addEntryToBuffer(java.lang.String docno,
int docLength,
FilePosition directIndexOffset)
throws java.io.IOException
docno - String the document number.docLength - int the number of indexed tokens in the document.directIndexOffset - FilePosition the ending position of the
document's entry in the direct index.
java.io.IOException - Throws an exception in the
case of an IO error.
ArrayOutOfBoundsException - The docno being written is too longpublic void close()
public void finishedCollections()
|
Terrier IR Platform 1.1.1 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||