Module: PowerIQ::Resource::ResponseHandler

Defined in:
lib/poweriq_client/resource/base.rb

Class Method Summary collapse

Class Method Details

.create(resource) ⇒ Object



15
16
17
18
19
20
21
22
# File 'lib/poweriq_client/resource/base.rb', line 15

def self.create(resource)
  Proc.new { |response,request,result,&block|
    resource.request = request
    resource.response = response
    response.return!(request, result, &block)
    response.json
  }
end