@Immutable public final class OptimalStringAlignment extends Object implements StringDistance
| Constructor and Description |
|---|
OptimalStringAlignment() |
| Modifier and Type | Method and Description |
|---|---|
double |
distance(String s1,
String s2)
Compute the distance between strings: the minimum number of operations
needed to transform one string into the other (insertion, deletion,
substitution of a single character, or a transposition of two adjacent
characters) while no substring is edited more than once.
|
public final double distance(String s1, String s2)
distance in interface StringDistances1 - the first input strings2 - the second input stringCopyright © 2016. All rights reserved.