Exception: Radar::API::Error

Inherits:
StandardError
  • Object
show all
Defined in:
lib/radar/api/errors/error.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**error_params) ⇒ Error

Returns a new instance of Error.



6
7
8
9
10
# File 'lib/radar/api/errors/error.rb', line 6

def initialize(**error_params)
  @code = error_params.dig(:code)
  @param = error_params.dig(:param)
  @message = error_params.dig(:message)
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



4
5
6
# File 'lib/radar/api/errors/error.rb', line 4

def code
  @code
end

#messageObject (readonly)

Returns the value of attribute message.



4
5
6
# File 'lib/radar/api/errors/error.rb', line 4

def message
  @message
end

#paramObject (readonly)

Returns the value of attribute param.



4
5
6
# File 'lib/radar/api/errors/error.rb', line 4

def param
  @param
end