Interface Posting

    • Method Detail

      • getId

        int getId()
        Return the id of the current posting. For the inverted index, this is the current docid; for the direct index it corresponds to the current term id.
        Returns:
        id of the posting.
      • getFrequency

        int getFrequency()
        Return the frequency of the term in the current document, in tokens.
        Returns:
        frequency of the term in the current document, in tokens.
      • getDocumentLength

        int getDocumentLength()
        Return the length of the document of the current posting in tokens. Usually uses the DocumentIndex, may do otherwise if document length statistics are in posting list.
        Returns:
        length of the document of the current posting in tokens.
      • setId

        @Deprecated
        default void setId​(int id)
        Deprecated.
        This will be removed in a future release
      • asWritablePosting

        WritablePosting asWritablePosting()
        Copy this posting to one free of an iterator. Kind of like a clone.
        Returns:
        an identical posting, but which can be manipulated free of this iterator