Class FuzzyStringMatchFilter.Similarity
- java.lang.Object
-
- com.evolveum.midpoint.prism.query.FuzzyStringMatchFilter.ThresholdMatchingMethod<Float>
-
- com.evolveum.midpoint.prism.query.FuzzyStringMatchFilter.Similarity
-
- All Implemented Interfaces:
FuzzyStringMatchFilter.FuzzyMatchingMethod
,Serializable
- Enclosing interface:
- FuzzyStringMatchFilter<T>
public static class FuzzyStringMatchFilter.Similarity extends FuzzyStringMatchFilter.ThresholdMatchingMethod<Float>
Trigram similarity TODO consider using Double instead of Float- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Similarity(Float threshold, boolean inclusive)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull Float
computeMatchMetricValue(String lValue, String rValue)
Computes the appropriate fuzzy match metric - the one that is being compared with the threshold.QName
getMethodName()
Class<Float>
getMetricValueClass()
Returns the Java type of the metric being used by this method (Integer, Float, ...).boolean
matches(String lValue, String rValue)
-
Methods inherited from class com.evolveum.midpoint.prism.query.FuzzyStringMatchFilter.ThresholdMatchingMethod
getAttributes, getThreshold, getThresholdRequired, isInclusive, toString
-
-
-
-
Constructor Detail
-
Similarity
public Similarity(Float threshold, boolean inclusive)
-
-
Method Detail
-
getMethodName
public QName getMethodName()
-
computeMatchMetricValue
@NotNull public @NotNull Float computeMatchMetricValue(String lValue, String rValue)
Description copied from class:FuzzyStringMatchFilter.ThresholdMatchingMethod
Computes the appropriate fuzzy match metric - the one that is being compared with the threshold. For example, Levenshtein edit distance (an integer value) or trigram similarity value (a float).- Specified by:
computeMatchMetricValue
in classFuzzyStringMatchFilter.ThresholdMatchingMethod<Float>
-
getMetricValueClass
public Class<Float> getMetricValueClass()
Description copied from class:FuzzyStringMatchFilter.ThresholdMatchingMethod
Returns the Java type of the metric being used by this method (Integer, Float, ...). TODO consider removal- Specified by:
getMetricValueClass
in classFuzzyStringMatchFilter.ThresholdMatchingMethod<Float>
-
-