|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.AbstractCollection<E>
java.util.AbstractSet<E>
java.util.TreeSet
TextDatabase.KeywordTreeSet
public class KeywordTreeSet
The KeywordTreeSet is a TreeSet of keywords
Field Summary | |
---|---|
protected Keyword |
_mostPopularKeyword
Holds the keyword with the highest frequency |
Constructor Summary | |
---|---|
KeywordTreeSet()
|
Method Summary | |
---|---|
int |
addKeyword(java.lang.String string)
Adds a keyword to the collection while managing the keyword's frequency and mantains the record of the most popular keyword |
boolean |
contains(java.lang.String KeywordName)
Returns true if a keywordname exists in the tree set |
Keyword |
getKeyword(java.lang.String KeywordName)
Gets the Keyword whose keyword name is KeywordName |
int |
getMostPopularKeywordFrequency()
Returns the most popular keyword's frequency |
double |
getNormalizedFrequency(Keyword Keyword)
Gets the normalized frequency of a keywordName Normalized Frequency = keyword's frequency / most popular keyword's frequency |
double |
getNormalizedFrequency(java.lang.String KeywordName)
Gets the normalized frequency of a keywordName Normalized Frequency = keyword's frequency / most popular keyword's frequency |
Methods inherited from class java.util.TreeSet |
---|
add, addAll, clear, clone, comparator, contains, first, headSet, isEmpty, iterator, last, remove, size, subSet, tailSet |
Methods inherited from class java.util.AbstractSet |
---|
equals, hashCode, removeAll |
Methods inherited from class java.util.AbstractCollection |
---|
containsAll, retainAll, toArray, toArray, toString |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.Set |
---|
containsAll, equals, hashCode, removeAll, retainAll, toArray, toArray |
Field Detail |
---|
protected Keyword _mostPopularKeyword
Constructor Detail |
---|
public KeywordTreeSet()
Method Detail |
---|
public int addKeyword(java.lang.String string)
public boolean contains(java.lang.String KeywordName)
public double getNormalizedFrequency(java.lang.String KeywordName)
public double getNormalizedFrequency(Keyword Keyword)
public int getMostPopularKeywordFrequency()
public Keyword getKeyword(java.lang.String KeywordName)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |