class RSolr::Client
def send_and_receive path, opts
which returns a simple hash,
sends it to the connection's +execute+ method
creates a request context hash,
When the :params[:wt] => :ruby, the response will be a hash, else a string.
+send_and_receive+ returns either a string or hash on a successful ruby request.
All other options are passed right along to the connection's +send_and_receive+ method (:get, :post, or :head)
:headers : optional - hash of request headers
:data : optional - post data -- if a hash is given, it's sent as "application/x-www-form-urlencoded"
:params : optional - the query string params in hash form
:method : required - the http method (:get, :post or :head)
"opt" : A hash, which can contain the following keys:
"path" : A string value that usually represents a solr request handler
+send_and_receive+ is the main request method responsible for sending requests to the +connection+ object.
def send_and_receive path, opts request_context = build_request path, opts execute request_context end