Module: StrMetrics::Jaro

Defined in:
lib/str_metrics.rb

Overview

Namespace for Jaro

Class Method Summary collapse

Class Method Details

.similarity(a, b, ignore_case: false) ⇒ Object



56
57
58
# File 'lib/str_metrics.rb', line 56

def self.similarity(a, b, ignore_case: false)
  Native.jaro_similarity(a&.to_utf8, b&.to_utf8, ignore_case ? 1 : 0)
end