Package org.terrier.structures
Interface DocumentIndex
-
- All Known Subinterfaces:
FieldDocumentIndex
- All Known Implementing Classes:
FSADocumentIndex,FSADocumentIndexInMem,FSADocumentIndexInMemFields,FSAFieldDocumentIndex,MemoryDocumentIndex,MemoryDocumentIndexFields,MemoryDocumentIndexFieldsMap,MemoryDocumentIndexMap,MultiDoc,PostingUtil.DocidSpecificDocumentIndex,StructureMerger.NullDocumentIndex
public interface DocumentIndexInterface for a document index.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description DocumentIndexEntrygetDocumentEntry(int docid)Return the document index entry based on its docid.intgetDocumentLength(int docid)Return the length of the document.intgetNumberOfDocuments()Return the number of documents.
-
-
-
Method Detail
-
getDocumentEntry
DocumentIndexEntry getDocumentEntry(int docid) throws java.io.IOException
Return the document index entry based on its docid.- Returns:
- the document index entry based on its docid.
- Throws:
java.io.IOException
-
getDocumentLength
int getDocumentLength(int docid) throws java.io.IOExceptionReturn the length of the document.- Returns:
- the length of the document.
- Throws:
java.io.IOException
-
getNumberOfDocuments
int getNumberOfDocuments()
Return the number of documents.- Returns:
- the number of documents.
-
-