Package de.hdm_stuttgart.mi.sd1.textstat
Class WordFrequency
java.lang.Object
de.hdm_stuttgart.mi.sd1.textstat.WordFrequency
A helper class to account for frequencies of words found in textual input.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Compare by word frequencies -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
word
The frequency of this word will be counted.
-
-
Constructor Details
-
WordFrequency
- Parameters:
word
- The immutable value. Has to be non-null.
-
-
Method Details
-
incrementFrequency
We found another one. Thus increment the total number to be returned bygetFrequency()
. -
getFrequency
- Returns:
- The number of appearances so far.
-
hashCode
-
equals
-