Method: Response#initialize

Defined in:
lib/kirin_http/http_response.rb

#initialize(content, headers, code) ⇒ Response

Returns a new instance of Response.

Parameters:

  • content (Object)

    the body of the http request

  • headers (Hash)

    the headers of the http request

  • code (Integer)

    the status code of the http request



6
7
8
9
10
# File 'lib/kirin_http/http_response.rb', line 6

def initialize(content, headers, code)
  @content = content
  @header = headers
  @code = code
end