Package org.terrier.structures.bit
Class BlockFieldDirectInvertedOutputStream
- java.lang.Object
-
- org.terrier.structures.AbstractPostingOutputStream
-
- org.terrier.structures.bit.DirectInvertedOutputStream
-
- org.terrier.structures.bit.FieldDirectInvertedOutputStream
-
- org.terrier.structures.bit.BlockFieldDirectInvertedOutputStream
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
public class BlockFieldDirectInvertedOutputStream extends FieldDirectInvertedOutputStream
Writes out a blocks and fields direct index to an output stream
-
-
Field Summary
-
Fields inherited from class org.terrier.structures.bit.DirectInvertedOutputStream
lastDocid, logger, output
-
-
Constructor Summary
Constructors Constructor Description BlockFieldDirectInvertedOutputStream(java.io.OutputStream os)
BlockFieldDirectInvertedOutputStream(java.lang.String filename)
Constructs an instance of the class withBlockFieldDirectInvertedOutputStream(BitOut out)
Constructs an instance of the class with
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Class<? extends IterablePosting>
getPostingIteratorClass()
Returns the IterablePosting class to use for reading structure written by this classprotected void
writePostingNotDocid(Posting _p)
Hook method for writing out the remainder of the posting-
Methods inherited from class org.terrier.structures.bit.DirectInvertedOutputStream
close, getBitOffset, getBitOut, getByteOffset, getLastDocidWritten, getOffset, writeNoFieldPostings, writePostings, writePostings, writePostings, writePostings, writePostings, writePostings
-
-
-
-
Constructor Detail
-
BlockFieldDirectInvertedOutputStream
public BlockFieldDirectInvertedOutputStream(BitOut out)
Constructs an instance of the class with- Parameters:
out
-
-
BlockFieldDirectInvertedOutputStream
public BlockFieldDirectInvertedOutputStream(java.lang.String filename) throws java.io.IOException
Constructs an instance of the class with- Parameters:
filename
-- Throws:
java.io.IOException
-
BlockFieldDirectInvertedOutputStream
public BlockFieldDirectInvertedOutputStream(java.io.OutputStream os) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
getPostingIteratorClass
public java.lang.Class<? extends IterablePosting> getPostingIteratorClass()
Description copied from class:DirectInvertedOutputStream
Returns the IterablePosting class to use for reading structure written by this class- Overrides:
getPostingIteratorClass
in classFieldDirectInvertedOutputStream
-
writePostingNotDocid
protected void writePostingNotDocid(Posting _p) throws java.io.IOException
Description copied from class:DirectInvertedOutputStream
Hook method for writing out the remainder of the posting- Overrides:
writePostingNotDocid
in classFieldDirectInvertedOutputStream
- Throws:
java.io.IOException
-
-