Exception: ThreeScaleToolbox::ThreeScaleApiError

Inherits:
Error
  • Object
show all
Defined in:
lib/3scale_toolbox/error.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Error

#kind, #stacktrace

Constructor Details

#initialize(msg = '', apierrors = {}) ⇒ ThreeScaleApiError

Returns a new instance of ThreeScaleApiError.



39
40
41
42
# File 'lib/3scale_toolbox/error.rb', line 39

def initialize(msg = '', apierrors = {})
  @apierrors = apierrors
  super(msg)
end

Instance Attribute Details

#apierrorsObject (readonly)

Returns the value of attribute apierrors.



37
38
39
# File 'lib/3scale_toolbox/error.rb', line 37

def apierrors
  @apierrors
end

Instance Method Details

#codeObject



48
49
50
# File 'lib/3scale_toolbox/error.rb', line 48

def code
  'E_3SCALE_API'
end

#messageObject



44
45
46
# File 'lib/3scale_toolbox/error.rb', line 44

def message
  "#{super}. Errors: #{apierrors}"
end