Click or drag to resize

MathUtilEditDistance Method (String, String, MathUtilEditDistanceOptions)

Verizon Connect Logo
Print this page
Learn more about Verizon Connect GeoBase.
Get information about the latest release
Gets the Levenshtein or Damerau-Levenshtein edit distance between two strings.

Namespace:  Telogis.GeoBase
Assembly:  geobase.net (in geobase.net.dll) Version: 4.99.0.0
Syntax
public static int EditDistance(
	string stringA,
	string stringB,
	MathUtilEditDistanceOptions options
)

Parameters

stringA
Type: SystemString
The first string to compare.
stringB
Type: SystemString
The second string to compare.
options
Type: Telogis.GeoBaseMathUtilEditDistanceOptions
Options controlling how the edit distance is calculated.

Return Value

Type: Int32
The Levenshtein or Damerau-Levenshtein edit distance. Returns -1 if one of the options is violated (for example, differing first characters when using EditDistanceOptions.RequireFirstCharacterMatch), or if either of the input strings is empty.
See Also