Class: LinkedIn::Response

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ Response

Returns a new instance of Response.



5
6
7
8
# File 'lib/linkedin/response.rb', line 5

def initialize(response)
  @_response = response
  @_body = response.body
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method, *args, &block) ⇒ Object



14
15
16
# File 'lib/linkedin/response.rb', line 14

def method_missing(method, *args, &block)
  _body.send method, *args, &block
end

Instance Attribute Details

#_bodyObject (readonly)

Returns the value of attribute _body.



3
4
5
# File 'lib/linkedin/response.rb', line 3

def _body
  @_body
end

#_responseObject (readonly)

Returns the value of attribute _response.



3
4
5
# File 'lib/linkedin/response.rb', line 3

def _response
  @_response
end

Instance Method Details

#_statusObject



10
11
12
# File 'lib/linkedin/response.rb', line 10

def _status
  _response.status
end