Exception: Ruberto::Error

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(msg, body, status) ⇒ Error

Returns a new instance of Error.



7
8
9
10
11
12
13
# File 'lib/ruberto/error.rb', line 7

def initialize(msg, body, status)
  @message = body[:message]
  @metadata = body[:metadata]
  @status = status

  super(msg)
end

Instance Attribute Details

#messageObject (readonly)

Returns the value of attribute message.



5
6
7
# File 'lib/ruberto/error.rb', line 5

def message
  @message
end

#metadataObject (readonly)

Returns the value of attribute metadata.



5
6
7
# File 'lib/ruberto/error.rb', line 5

def 
  @metadata
end

#statusObject (readonly)

Returns the value of attribute status.



5
6
7
# File 'lib/ruberto/error.rb', line 5

def status
  @status
end