|
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.merging.StructureMerger
public class StructureMerger
This class merges the structures created by Terrier, so that we use fewer and larger inverted and direct files.
Properties:
Constructor Summary | |
---|---|
StructureMerger(Index _srcIndex1,
Index _srcIndex2,
Index _destIndex)
|
|
StructureMerger(java.lang.String _srcfilename1,
java.lang.String _srcfilename2)
Deprecated. |
Method Summary | |
---|---|
static void |
main(java.lang.String[] args)
Usage: java uk.ac.gla.terrier.structures.merging.StructureMerger [binary bits] [inverted file 1] [inverted file 2] [output inverted file] |
void |
mergeStructures()
Merges the structures created by terrier. |
void |
setNumberOfBits(int bits)
Sets the number of bits to write or read for binary encoded numbers |
void |
setOutputFilename(java.lang.String _outputName)
Deprecated. |
void |
setOutputIndex(Index _outputIndex)
Sets the output index. |
static void |
writeFieldPostings(int[][] postings,
int firstId,
BitOut output,
int binaryBits)
Deprecated. use DirectInvertedIndexOutputStream |
static void |
writeNoFieldPostings(int[][] postings,
int firstId,
BitOut output)
Deprecated. use DirectInvertedIndexOutputStream |
static void |
writePostings(int[][] postings,
int firstId,
BitOut output,
int binaryBits)
Deprecated. Please use DirectInvertedOutputStream instead |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StructureMerger(Index _srcIndex1, Index _srcIndex2, Index _destIndex)
public StructureMerger(java.lang.String _srcfilename1, java.lang.String _srcfilename2)
_srcfilename1
- the first inverted file to merge_srcfilename2
- the second inverted file to mergeMethod Detail |
---|
public void setNumberOfBits(int bits)
bits
- the number of bits to write or readpublic void setOutputFilename(java.lang.String _outputName)
_outputName
- the filename of the merged inverted filepublic void setOutputIndex(Index _outputIndex)
_outputIndex
- the index to be merged topublic void mergeStructures()
public static void main(java.lang.String[] args)
Binary bits concerns the number of fields in use in the index.
public static void writePostings(int[][] postings, int firstId, BitOut output, int binaryBits) throws java.io.IOException
postings
- the postings list to write.firstId
- the first identifier to write. This can be
an id plus one, or the gap of the current id and the previous one.output
- the output bit file.
java.io.IOException
public static void writeFieldPostings(int[][] postings, int firstId, BitOut output, int binaryBits) throws java.io.IOException
postings
- the postings list to write.firstId
- the first identifier to write. This can be
an id plus one, or the gap of the current id and the previous one.output
- the output bit file.
java.io.IOException
public static void writeNoFieldPostings(int[][] postings, int firstId, BitOut output) throws java.io.IOException
postings
- the postings list to write.firstId
- the first identifier to write. This can be
an id plus one, or the gap of the current id and the previous one.output
- the output bit file.
java.io.IOException
- if an error occurs during writing to a file.
|
Terrier IR Platform 2.2.1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |