Class: PaysonAPI::V1::Responses::PaymentUpdate

Inherits:
Object
  • Object
show all
Defined in:
lib/payson_api/v1/responses/payment_update.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ PaymentUpdate

Returns a new instance of PaymentUpdate.



9
10
11
12
# File 'lib/payson_api/v1/responses/payment_update.rb', line 9

def initialize(data)
  @envelope = PaysonAPI::V1::Envelope.parse(data)
  @errors = PaysonAPI::V1::RemoteError.parse(data)
end

Instance Attribute Details

#envelopeObject

Returns the value of attribute envelope.



7
8
9
# File 'lib/payson_api/v1/responses/payment_update.rb', line 7

def envelope
  @envelope
end

#errorsObject

Returns the value of attribute errors.



7
8
9
# File 'lib/payson_api/v1/responses/payment_update.rb', line 7

def errors
  @errors
end

Instance Method Details

#success?Boolean

Returns:

  • (Boolean)


14
15
16
# File 'lib/payson_api/v1/responses/payment_update.rb', line 14

def success?
  @envelope.ack == 'SUCCESS'
end