|
Terrier IR Platform 2.2.1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object uk.ac.gla.terrier.structures.indexing.singlepass.Inverted2DirectIndexBuilder
public class Inverted2DirectIndexBuilder
Create a direct index from an InvertedIndex. The algorithm is similar to that followed by InvertedIndexBuilder. To summarise, InvertedIndexBuilder builds an InvertedIndex from a DirectIndex. This class does the opposite, building a DirectIndex from an InvertedIndex.
Algorithm:
For a selection of document ids
(Scan the inverted index looking for postings with these document ids)
For each term in the inverted index
Select required postings from all the postings of that term
Add these to posting objects that represents each document
&nsbp;For each posting object
Write out the postings for that document
Notes:
This algorithm assumes that termids start at 0 and are strictly increasing. This assumption holds true
only for inverted indices generated by the single pass indexing method.
Properties:
Constructor Summary | |
---|---|
Inverted2DirectIndexBuilder(Index i)
Construct a new instance of this builder class |
Method Summary | |
---|---|
void |
createDirectIndex()
create the direct index when the collection contains an existing inverted index |
static void |
main(java.lang.String[] args)
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Inverted2DirectIndexBuilder(Index i)
Method Detail |
---|
public void createDirectIndex()
public static void main(java.lang.String[] args)
|
Terrier IR Platform 2.2.1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |