Class FSADocumentIndexInMem

java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractList<V>
All Implemented Interfaces:
java.io.Closeable, java.lang.AutoCloseable, java.lang.Iterable<DocumentIndexEntry>, java.util.Collection<DocumentIndexEntry>, java.util.List<DocumentIndexEntry>, DocumentIndex
Direct Known Subclasses:
FSADocumentIndexInMemFields

public class FSADocumentIndexInMem
extends FSArrayFileInMem<DocumentIndexEntry>
implements DocumentIndex
A DocumentIndex implementation that loads everything in memory. It is not compatible with fields.
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.terrier.structures.collections.FSArrayFile

    FSArrayFile.ArrayFileIterator<V extends org.apache.hadoop.io.Writable>, FSArrayFile.ArrayFileWriter
  • Field Summary

    Fields 
    Modifier and Type Field Description
    protected int[] docLengths  
    protected int lastDocid  
    protected DocumentIndexEntry lastEntry  

    Fields inherited from class org.terrier.structures.collections.FSArrayFile

    dataFile, dataFilename, entrySize, numberOfEntries, USUAL_EXTENSION, valueFactory

    Fields inherited from class java.util.AbstractList

    modCount
  • Constructor Summary

    Constructors 
    Constructor Description
    FSADocumentIndexInMem​(IndexOnDisk index, java.lang.String structureName)  
  • Method Summary

    Modifier and Type Method Description
    DocumentIndexEntry getDocumentEntry​(int docid)  
    int getDocumentLength​(int docid)  
    int getNumberOfDocuments()  

    Methods inherited from class org.terrier.structures.collections.FSArrayFileInMem

    get

    Methods inherited from class org.terrier.structures.collections.FSArrayFile

    close, iterator, size, writeFSArrayFile

    Methods inherited from class java.util.AbstractList

    add, add, addAll, clear, equals, hashCode, indexOf, lastIndexOf, listIterator, listIterator, remove, removeRange, set, subList

    Methods inherited from class java.util.AbstractCollection

    addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toString

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface java.util.Collection

    parallelStream, removeIf, stream, toArray

    Methods inherited from interface java.lang.Iterable

    forEach

    Methods inherited from interface java.util.List

    addAll, contains, containsAll, isEmpty, remove, removeAll, replaceAll, retainAll, sort, spliterator, toArray, toArray