def search(query, options={})
            options = { :start => 0, :len => 10 }.merge(options)
            options.merge!( :q => query )
            begin
                code, r = GET "/search", options
                return r
            rescue HttpCodeException
                raise
            end
        end
def search(query, options={})
            options = { :start => 0, :len => 10 }.merge(options)
            options.merge!( :q => query )
            begin
                code, r = GET "/search", options
                return r
            rescue HttpCodeException
                raise
            end
        end
the options argument may contain an :index_code definition to override
 this instance's default index_code
 it can also contain any of the following:
   :start => an int with the number of results to skip
   :len => an int with the number of results to return
   :snippet => a comma separated list of field names for which a snippet
               should be returned. (requires an index that supports snippets)
   :fetch => a comma separated list of field names for which its content
             should be returned. (requires an index that supports storage)
   :function => an int with the index of the scoring function to be used
                for this query