Class: HTTPalooza::Players::RestClientPlayer

Inherits:
Base
  • Object
show all
Defined in:
lib/httpalooza/players/rest_client.rb

Instance Attribute Summary

Attributes inherited from Base

#request

Instance Method Summary collapse

Methods inherited from Base

execute!, #initialize, introducing!, #name

Constructor Details

This class inherits a constructor from HTTPalooza::Players::Base

Instance Method Details

#responseObject



6
7
8
9
10
11
12
13
14
# File 'lib/httpalooza/players/rest_client.rb', line 6

def response
  response = RestClient::Request.execute(
    :method => request.method,
    :url => request.url.to_s,
    :payload => request.payload,
    :headers => request.headers
  )
  Response.new(response.code, response.to_str)
end