|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.archiviststoolkit.util.FuzzyStringMatcher
public class FuzzyStringMatcher
Utility class, providing methods for a fuzzy comparison between strings.
Method Summary | |
---|---|
static float |
getMatchRate(java.lang.String string1,
java.lang.String string2)
Calculates the match rate, a value between 0 and 1, proportional to the rate the two strings match (1 is exact match). |
static int |
getMismatch(java.lang.String string1,
java.lang.String string2)
Calculates the mismatch between two strings. |
static java.lang.String |
normalizeString(java.lang.String str)
Creates normalized title. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static int getMismatch(java.lang.String string1, java.lang.String string2)
string1
- first stringstring2
- second string
public static float getMatchRate(java.lang.String string1, java.lang.String string2)
string1
- first stringstring2
- second string
public static java.lang.String normalizeString(java.lang.String str)
str
- The original title.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |