Class: Ravelin::CheckoutTransaction

Inherits:
RavelinObject show all
Defined in:
lib/ravelin/checkout_transaction.rb

Overview

Represents a transaction as used in the checkout endpoint. As such it can have all the fields of a regular Transaction but only requires the fields of PreTransaction

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RavelinObject

attr_accessor, attr_required, required_attributes, #serializable_hash, #validate

Constructor Details

#initialize(params) ⇒ CheckoutTransaction

Returns a new instance of CheckoutTransaction.



24
25
26
27
28
29
30
31
# File 'lib/ravelin/checkout_transaction.rb', line 24

def initialize(params)
  unless params['3ds'].nil?
    self.three_d_secure = ThreeDSecure.new(params['3ds'])
    params.delete('3ds')
  end

  super(params)
end

Instance Attribute Details

#auth_codeObject

Returns the value of attribute auth_code.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def auth_code
  @auth_code
end

#avs_result_codeObject

Returns the value of attribute avs_result_code.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def avs_result_code
  @avs_result_code
end

#creditObject

Returns the value of attribute credit.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def credit
  @credit
end

#currencyObject

Returns the value of attribute currency.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def currency
  @currency
end

#customObject

Returns the value of attribute custom.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def custom
  @custom
end

#cvv_result_codeObject

Returns the value of attribute cvv_result_code.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def cvv_result_code
  @cvv_result_code
end

#debitObject

Returns the value of attribute debit.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def debit
  @debit
end

#decline_codeObject

Returns the value of attribute decline_code.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def decline_code
  @decline_code
end

#emailObject

Returns the value of attribute email.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def email
  @email
end

#gatewayObject

Returns the value of attribute gateway.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def gateway
  @gateway
end

#gateway_referenceObject

Returns the value of attribute gateway_reference.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def gateway_reference
  @gateway_reference
end

#successObject

Returns the value of attribute success.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def success
  @success
end

#three_d_secureObject

Returns the value of attribute three_d_secure.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def three_d_secure
  @three_d_secure
end

#timeObject

Returns the value of attribute time.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def time
  @time
end

#transaction_idObject

Returns the value of attribute transaction_id.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def transaction_id
  @transaction_id
end

#typeObject

Returns the value of attribute type.



5
6
7
# File 'lib/ravelin/checkout_transaction.rb', line 5

def type
  @type
end