Class: CurlAdapter::Response

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(http_response_code, time_total) ⇒ Response

Returns a new instance of Response.



7
8
9
10
# File 'lib/curl_adapter.rb', line 7

def initialize(http_response_code, time_total)
  @http_response_code = http_response_code
  @time_total = time_total
end

Instance Attribute Details

#http_response_codeObject (readonly)

Returns the value of attribute http_response_code.



4
5
6
# File 'lib/curl_adapter.rb', line 4

def http_response_code
  @http_response_code
end

#time_totalObject (readonly)

Returns the value of attribute time_total.



5
6
7
# File 'lib/curl_adapter.rb', line 5

def time_total
  @time_total
end

Instance Method Details

#inspectObject



12
13
14
# File 'lib/curl_adapter.rb', line 12

def inspect
  "#{@http_response_code} #{@time_total} sec"
end