am 96717371: am e8825ce3: am 1fd10ea2: Merge "Throw illegal argument exception in BinaryDictionary::editDistance" into jb-mr1-dev
* commit '967173711f17ba30d3608881f501985f07fef4fd': Throw illegal argument exception in BinaryDictionary::editDistancemain
commit
69c787f3b7
|
@ -187,6 +187,9 @@ public final class BinaryDictionary extends Dictionary {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static int editDistance(String before, String after) {
|
public static int editDistance(String before, String after) {
|
||||||
|
if (before == null || after == null) {
|
||||||
|
throw new IllegalArgumentException();
|
||||||
|
}
|
||||||
return editDistanceNative(before.toCharArray(), after.toCharArray());
|
return editDistanceNative(before.toCharArray(), after.toCharArray());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue