Class: Paymongo::PaymongoError

Inherits:
Object
  • Object
show all
Defined in:
lib/paymongo/paymongo_error.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(error) ⇒ PaymongoError

Returns a new instance of PaymongoError.



7
8
9
10
11
# File 'lib/paymongo/paymongo_error.rb', line 7

def initialize(error)
  @code = error['code']
  @detail = error['detail']
  @source = error['source']
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



3
4
5
# File 'lib/paymongo/paymongo_error.rb', line 3

def code
  @code
end

#detailObject (readonly)

Returns the value of attribute detail.



3
4
5
# File 'lib/paymongo/paymongo_error.rb', line 3

def detail
  @detail
end

#sourceObject (readonly)

Returns the value of attribute source.



3
4
5
# File 'lib/paymongo/paymongo_error.rb', line 3

def source
  @source
end