public class IndexedTermSimilarityRelation extends AbstractRelation<IndexedTerm,IndexedTerm>
Modifier and Type | Field and Description |
---|---|
protected double |
similarity
The similarity between the two terms.
|
source, target
Constructor and Description |
---|
IndexedTermSimilarityRelation(IndexedTerm source,
IndexedTerm target,
double similarity)
Creates a new
IndexedTermSimilarityRelation . |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(IndexedTermSimilarityRelation other)
Determines if this object is equal to the given object.
|
boolean |
equals(java.lang.Object other) |
double |
getSimilarity()
Gets the similarity between the two terms.
|
int |
hashCode() |
protected void |
setSimilarity(double similarity)
Sets the similarity between the two terms.
|
getSource, getTarget, setSource, setTarget
clone
public IndexedTermSimilarityRelation(IndexedTerm source, IndexedTerm target, double similarity)
IndexedTermSimilarityRelation
.source
- The source term.target
- The target term.similarity
- The similarity between the terms.public boolean equals(java.lang.Object other)
equals
in class java.lang.Object
public boolean equals(IndexedTermSimilarityRelation other)
other
- Another object.public int hashCode()
hashCode
in class java.lang.Object
public double getSimilarity()
protected void setSimilarity(double similarity)
similarity
- The similarity between the two terms.