Package org.terrier.structures.merging
Class LexiconMerger
- java.lang.Object
-
- org.terrier.structures.merging.LexiconMerger
-
public class LexiconMerger extends java.lang.Object
Merges many lexicons, termids and offsets are not kept.- Author:
- Vassilis Plachouras
-
-
Field Summary
Fields Modifier and Type Field Description protected IndexOnDisk
destIndex
protected IndexOnDisk
srcIndex1
protected IndexOnDisk
srcIndex2
-
Constructor Summary
Constructors Constructor Description LexiconMerger(IndexOnDisk src1, IndexOnDisk src2, IndexOnDisk dest)
A constructor that sets the filenames of the lexicon files to merge
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
main(java.lang.String[] args)
mainvoid
mergeLexicons()
Merges the two lexicons into one.
-
-
-
Field Detail
-
srcIndex1
protected IndexOnDisk srcIndex1
-
srcIndex2
protected IndexOnDisk srcIndex2
-
destIndex
protected IndexOnDisk destIndex
-
-
Constructor Detail
-
LexiconMerger
public LexiconMerger(IndexOnDisk src1, IndexOnDisk src2, IndexOnDisk dest)
A constructor that sets the filenames of the lexicon files to merge- Parameters:
src1
- Source index 1src2
- Source index 2dest
- Destination index
-
-
Method Detail
-
mergeLexicons
public void mergeLexicons()
Merges the two lexicons into one. After this stage, the offsets in the lexicon are not correct. They will be updated only after creating the inverted file.
-
main
public static void main(java.lang.String[] args) throws java.lang.Exception
main- Parameters:
args
-- Throws:
java.lang.Exception
-
-