Class LexiconEntry

    • Constructor Detail

      • LexiconEntry

        public LexiconEntry()
    • Method Detail

      • toString

        public java.lang.String toString()
        returns a string representation of this lexicon entry
        toString in class java.lang.Object
      • setTermId

        public abstract void setTermId​(int newTermId)
        Set the term ID, the integer representation of the term in the index, e.g. as used in direct index posting structures.
      • setStatistics

        public abstract void setStatistics​(int n_t,
                                           int TF)
        Update the document frequency and term frequency
      • getNumberOfEntries

        public int getNumberOfEntries()
        Pointer implementation: how many entries in the inverted index. Usually the same as getDocumentFrequency().
        Specified by:
        getNumberOfEntries in interface Pointer
        the number of "things" that this pointer refers to.
      • setNumberOfEntries

        public void setNumberOfEntries​(int n)
        Update the number of entries in the pointer
        Specified by:
        setNumberOfEntries in interface Pointer
        n - the number of "things" that the pointer refers to.
      • pointerToString

        public java.lang.String pointerToString()
        Description copied from interface: Pointer
        Returns a textual representation of the pointer alone
        Specified by:
        pointerToString in interface Pointer
      • setPointer

        public void setPointer​(Pointer p)
        Update the pointer
        Specified by:
        setPointer in interface Pointer
        p - other pointer to update the pointer in this object.
      • getWritableEntryStatistics

        public EntryStatistics getWritableEntryStatistics()
        Get a writable copy of the EntryStatistics. Just returns itself.
        Specified by:
        getWritableEntryStatistics in interface EntryStatistics
        an identical entry statistics, but which can be reused.
      • equals

        public boolean equals​(java.lang.Object obj)
        Does this refer to the same term
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        hash this object based on termid
        hashCode in class java.lang.Object