Changeset 14373 in josm
- Timestamp:
- 2018-10-27T15:41:32+02:00 (5 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/scripts/I18nSimilarStrings.java
r14138 r14373 6 6 import org.openstreetmap.josm.data.preferences.JosmBaseDirectories; 7 7 import org.openstreetmap.josm.data.preferences.JosmUrls; 8 import org.openstreetmap.josm.data.validation.tests.SimilarNamedWays;9 8 import org.openstreetmap.josm.gui.MainApplicationTest; 10 9 import org.openstreetmap.josm.plugins.PluginHandlerTestIT; 11 10 import org.openstreetmap.josm.spi.preferences.Config; 12 11 import org.openstreetmap.josm.tools.I18n; 12 import org.openstreetmap.josm.tools.Utils; 13 13 14 14 // License: GPL. For details, see LICENSE file. … … 45 45 String a = strings.get(i); 46 46 String b = strings.get(j); 47 int d = SimilarNamedWays.getLevenshteinDistance(a, b);47 int d = Utils.getLevenshteinDistance(a, b); 48 48 if (d <= 2) { 49 49 System.err.println(": " + a + " <--> " + b); -
trunk/src/org/openstreetmap/josm/data/validation/tests/SimilarNamedWays.java
r14371 r14373 111 111 112 112 /** 113 * Compute Levenshtein distance 114 * 115 * @param s First word 116 * @param t Second word 117 * @return The distance between words 118 * @deprecated Use {@link Utils#getLevenshteinDistance} instead 119 */ 120 @Deprecated 121 public static int getLevenshteinDistance(String s, String t) { 122 return Utils.getLevenshteinDistance(s, t); 123 } 124 125 /** 113 126 * Add a regular expression rule. 114 127 * @param regExpr the regular expression to search for
Note:
See TracChangeset
for help on using the changeset viewer.