|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.hpi.fgis.dude.similarityfunction.contentbased.calculationstrategy.IgnoreStrategy<T1,T2>
T1
- The type of the first value.T2
- The type of the second value.public class IgnoreStrategy<T1 extends JsonValue,T2 extends JsonValue>
IgnoreStrategy
ignores the actual values and returns always the same default similarity. The number of times this strategy was used
can be reviewed using getCallCount()
.
Constructor Summary | |
---|---|
IgnoreStrategy()
Initializes a IgnoreStrategy that returns a default similarity of 0.0 . |
|
IgnoreStrategy(double defSimilarity)
Initializes a IgnoreStrategy that returns the passed default similarity. |
Method Summary | |
---|---|
double |
calculateSimilarity(ContentBasedSimilarityFunction<?> similarityFunction,
T1 value1,
T2 value2)
Calculates the similarity of the passed values. |
int |
getCallCount()
Returns the current call count. |
void |
resetCallCount()
Resets the call count. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public IgnoreStrategy()
IgnoreStrategy
that returns a default similarity of 0.0
.
public IgnoreStrategy(double defSimilarity)
IgnoreStrategy
that returns the passed default similarity.
defSimilarity
- The similarity that shall be returned by any call of
calculateSimilarity(ContentBasedSimilarityFunction, JsonValue, JsonValue)
.Method Detail |
---|
public double calculateSimilarity(ContentBasedSimilarityFunction<?> similarityFunction, T1 value1, T2 value2)
CalculationStrategy
calculateSimilarity
in interface CalculationStrategy<T1 extends JsonValue,T2 extends JsonValue>
similarityFunction
- The SimilarityFunction
that is used for atomic values within this strategy.value1
- The first value.value2
- The second value.
public int getCallCount()
public void resetCallCount()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |