method

levenshtein_distance

levenshtein_distance(str1, str2)
private

This code is based directly on the Text gem implementation. Copyright © 2006-2013 Paul Battley, Michael Neumann, Tim Fletcher.

Returns a value representing the “cost” of transforming str1 into str2.