Class: Droonga::SearchHandler

Inherits:
HandlerPlugin show all
Defined in:
lib/droonga/plugin/handler/search.rb

Instance Method Summary collapse

Methods inherited from HandlerPlugin

#emit, #envelope, #initialize, #post, #prefer_synchronous?

Methods included from PluginRegisterable

#command, extended, #inherited, #method_name, #processable?, #repository

Methods inherited from Plugin

#initialize, #process, #processable?, #shutdown, #start

Constructor Details

This class inherits a constructor from Droonga::HandlerPlugin

Instance Method Details

#search(request) ⇒ Object



26
27
28
29
30
31
# File 'lib/droonga/plugin/handler/search.rb', line 26

def search(request)
  searcher = Droonga::Searcher.new(@context)
  searcher.search(request["queries"]).each do |output, value|
    emit(value, output)
  end
end