|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.ontopia.topicmaps.classify.Term
public class Term
PUBLIC: Represents a concept which occurs in the classified content. A term can have many variants, all of which can be found from this object. It also has a score, indicating the importance of the term within the content.
Field Summary | |
---|---|
protected double |
score
|
protected static java.util.Comparator |
SCORE_COMPARATOR
|
protected java.lang.String |
stem
|
protected int |
totalOccurrences
|
protected gnu.trove.TObjectIntHashMap<Variant> |
variants
|
Method Summary | |
---|---|
protected void |
addScore(double ascore,
java.lang.String reason)
|
protected void |
addVariant(Variant variant)
|
protected void |
addVariant(Variant variant,
int occurrences)
|
protected void |
divideScore(double factor,
java.lang.String reason)
|
int |
getOccurrences()
PUBLIC: Returns the number of times the term occurred within the classified content. |
protected int |
getOccurrences(Variant variant)
|
java.lang.String |
getPreferredName()
PUBLIC: Returns the preferred variant of the term. |
double |
getScore()
PUBLIC: Returns the term's score, a number in the range 0-1, indicating its importance within the content. |
protected double |
getScore(Variant v)
|
java.lang.String |
getStem()
PUBLIC: Returns the stem common to all variants of the term. |
Variant[] |
getVariants()
PUBLIC: Returns all variant spellings of this term within the content. |
Variant[] |
getVariantsByRank()
PUBLIC: Returns all variant spellings of this term within the content, with the most important first. |
protected void |
merge(Term other)
|
protected void |
multiplyScore(double factor,
java.lang.String reason)
|
protected void |
setScore(double score,
java.lang.String reason)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.lang.String stem
protected double score
protected int totalOccurrences
protected gnu.trove.TObjectIntHashMap<Variant> variants
protected static java.util.Comparator SCORE_COMPARATOR
Method Detail |
---|
public java.lang.String getStem()
public double getScore()
public Variant[] getVariants()
public Variant[] getVariantsByRank()
public int getOccurrences()
public java.lang.String getPreferredName()
protected double getScore(Variant v)
protected int getOccurrences(Variant variant)
protected void setScore(double score, java.lang.String reason)
protected void addScore(double ascore, java.lang.String reason)
protected void multiplyScore(double factor, java.lang.String reason)
protected void divideScore(double factor, java.lang.String reason)
protected void addVariant(Variant variant)
protected void addVariant(Variant variant, int occurrences)
protected void merge(Term other)
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |