Sha256: f5c9d423203575257b965cfc45ffc4cb754eca4bb711e19dc8152b40778c2b4b

Contents?: true

Size: 498 Bytes

Versions: 107

Compression:

Stored size: 498 Bytes

Contents

module Picky

  # encoding: utf-8
  #
  module Generators

    module Similarity

      # It's actually a combination of metaphone
      # and Levenshtein.
      #
      # It uses the metaphone to get similar words
      # and ranks them using the levenshtein.
      #
      class Metaphone < Phonetic

        # Encodes the given string/symbol.
        #
        # Returns a symbol.
        #
        def encode str_or_sym
          str_or_sym.metaphone
        end

      end

    end

  end

end

Version data entries

107 entries across 107 versions & 1 rubygems

Version Path
picky-4.31.3 lib/picky/generators/similarity/metaphone.rb
picky-4.31.2 lib/picky/generators/similarity/metaphone.rb
picky-4.31.1 lib/picky/generators/similarity/metaphone.rb
picky-4.31.0 lib/picky/generators/similarity/metaphone.rb
picky-4.30.0 lib/picky/generators/similarity/metaphone.rb
picky-4.29.0 lib/picky/generators/similarity/metaphone.rb
picky-4.28.1 lib/picky/generators/similarity/metaphone.rb
picky-4.27.1 lib/picky/generators/similarity/metaphone.rb
picky-4.27.0 lib/picky/generators/similarity/metaphone.rb
picky-4.26.2 lib/picky/generators/similarity/metaphone.rb
picky-4.26.1 lib/picky/generators/similarity/metaphone.rb
picky-4.26.0 lib/picky/generators/similarity/metaphone.rb
picky-4.25.3 lib/picky/generators/similarity/metaphone.rb
picky-4.25.2 lib/picky/generators/similarity/metaphone.rb
picky-4.25.1 lib/picky/generators/similarity/metaphone.rb
picky-4.25.0 lib/picky/generators/similarity/metaphone.rb
picky-4.24.0 lib/picky/generators/similarity/metaphone.rb
picky-4.23.2 lib/picky/generators/similarity/metaphone.rb
picky-4.23.1 lib/picky/generators/similarity/metaphone.rb
picky-4.23.0 lib/picky/generators/similarity/metaphone.rb