Class: Animoto::HTTPEngines::CurlAdapter

Inherits:
Base
  • Object
show all
Defined in:
lib/animoto/http_engines/curl_adapter.rb

Instance Method Summary collapse

Instance Method Details

#request(method, url, body = nil, headers = {}, options = {}) ⇒ String

Returns:

  • (String)


8
9
10
11
12
# File 'lib/animoto/http_engines/curl_adapter.rb', line 8

def request method, url, body = nil, headers = {}, options = {}
  curl = build_curl method, url, body, headers, options
  perform curl, method, body
  [curl.response_code, curl.body_str]
end