Class: Android::Publisher::Response

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

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(body) ⇒ Response

Returns a new instance of Response.



15
16
17
# File 'lib/android/publisher/response.rb', line 15

def initialize(body)

end

Class Method Details

.parse(response) ⇒ Object

TODO: create proper object instead of parsing response



6
7
8
9
10
11
12
# File 'lib/android/publisher/response.rb', line 6

def parse(response)
  if response.status == 204
    { :status => "OK" }
  else
    JSON.parse response.body
  end
end