Sha256: 21dbb457436f2992f292fdfaf1b0b355947d70b9764ee762ad0b1f940a218d45

Contents?: true

Size: 507 Bytes

Versions: 1

Compression:

Stored size: 507 Bytes

Contents

module Picky

  # TODO
  #
  class Category

    # TODO
    #
    def remove id
      indexed_exact.remove id
      indexed_partial.remove id
    end

    # TODO
    #
    def add id, tokens
      tokens.each do |text|
        next unless text
        text = text.to_sym
        indexed_exact.add id, text

        # TODO Beautify.
        #
        indexed_partial.partial_strategy.each_partial text do |partial_text|
          indexed_partial.add id, partial_text
        end
      end
    end

  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
picky-3.1.10 lib/picky/category_realtime.rb