String ExtensionsLevenshtein Normalized(String, String, Levenshtein Options) Method
Returns the normalized Levenshtein distance between source and pattern with the given poptions.
Definition
Namespace: SphinxConnector.FluentApi.Util
Assembly: SphinxConnector (in SphinxConnector.dll) Version: 6.1.0
The normalized Levenshtein distance, i.e. a value between 0.0 and 1.0 where 0.0 means source and pattern are equal and 1.0 representing the maximum difference.
Assembly: SphinxConnector (in SphinxConnector.dll) Version: 6.1.0
C#
public static float LevenshteinNormalized(
this string source,
string pattern,
LevenshteinOptions options
)VB
<ExtensionAttribute>
Public Shared Function LevenshteinNormalized (
source As String,
pattern As String,
options As LevenshteinOptions
) As SingleParameters
- source String
- The source string.
- pattern String
- The pattern string.
- options LevenshteinOptions
- The options for calculating the normalized Levenshtein distance.
Return Value
SingleThe normalized Levenshtein distance, i.e. a value between 0.0 and 1.0 where 0.0 means source and pattern are equal and 1.0 representing the maximum difference.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type String. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).Remarks
Supported with Manticore Search 4.0.2 and up.