Exception: Skydrive::APIResponseErrorException

Inherits:
RuntimeError
  • Object
show all
Defined in:
lib/skydrive/client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ APIResponseErrorException

Returns a new instance of APIResponseErrorException.



15
16
17
18
19
20
# File 'lib/skydrive/client.rb', line 15

def initialize(response)
  @response = response
  @code = response['error']
  @description = response['error_description']
  super("#{@code}: #{@description}\n#{response}")
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



14
15
16
# File 'lib/skydrive/client.rb', line 14

def code
  @code
end

#descriptionObject (readonly)

Returns the value of attribute description.



14
15
16
# File 'lib/skydrive/client.rb', line 14

def description
  @description
end

#responseObject (readonly)

Returns the value of attribute response.



14
15
16
# File 'lib/skydrive/client.rb', line 14

def response
  @response
end