Exception: Synoppy::Error

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

Overview

Raised when the API returns an error response.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, code, status) ⇒ Error

Returns a new instance of Error.



16
17
18
19
20
# File 'lib/synoppy.rb', line 16

def initialize(message, code, status)
  super(message)
  @code = code
  @status = status
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



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

def code
  @code
end

#statusObject (readonly)

Returns the value of attribute status.



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

def status
  @status
end