Class: OnlinePayments::SDK::Domain::RedirectPaymentProduct5300SpecificInput

Inherits:
DataObject
  • Object
show all
Defined in:
lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from DataObject

new_from_hash

Instance Attribute Details

#birth_cityString

Returns the current value of birth_city.

Returns:

  • (String)

    the current value of birth_city



20
21
22
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 20

def birth_city
  @birth_city
end

#birth_countryString

Returns the current value of birth_country.

Returns:

  • (String)

    the current value of birth_country



20
21
22
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 20

def birth_country
  @birth_country
end

#birth_zip_codeString

Returns the current value of birth_zip_code.

Returns:

  • (String)

    the current value of birth_zip_code



20
21
22
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 20

def birth_zip_code
  @birth_zip_code
end

#channelString

Returns the current value of channel.

Returns:

  • (String)

    the current value of channel



20
21
22
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 20

def channel
  @channel
end

#loyalty_card_numberString

Returns the current value of loyalty_card_number.

Returns:

  • (String)

    the current value of loyalty_card_number



20
21
22
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 20

def loyalty_card_number
  @loyalty_card_number
end

#second_installment_payment_dateString

Returns the current value of second_installment_payment_date.

Returns:

  • (String)

    the current value of second_installment_payment_date



20
21
22
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 20

def second_installment_payment_date
  @second_installment_payment_date
end

#session_durationInteger

Returns the current value of session_duration.

Returns:

  • (Integer)

    the current value of session_duration



20
21
22
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 20

def session_duration
  @session_duration
end

#titleString

Returns the current value of title.

Returns:

  • (String)

    the current value of title



20
21
22
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 20

def title
  @title
end

#transaction_expiration_date_timeDateTime

Returns the current value of transaction_expiration_date_time.

Returns:

  • (DateTime)

    the current value of transaction_expiration_date_time



20
21
22
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 20

def transaction_expiration_date_time
  @transaction_expiration_date_time
end

Instance Method Details

#from_hash(hash) ⇒ Object



55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 55

def from_hash(hash)
  super
  if hash.has_key? 'birthCity'
    @birth_city = hash['birthCity']
  end
  if hash.has_key? 'birthCountry'
    @birth_country = hash['birthCountry']
  end
  if hash.has_key? 'birthZipCode'
    @birth_zip_code = hash['birthZipCode']
  end
  if hash.has_key? 'channel'
    @channel = hash['channel']
  end
  if hash.has_key? 'loyaltyCardNumber'
    @loyalty_card_number = hash['loyaltyCardNumber']
  end
  if hash.has_key? 'secondInstallmentPaymentDate'
    @second_installment_payment_date = hash['secondInstallmentPaymentDate']
  end
  if hash.has_key? 'sessionDuration'
    @session_duration = hash['sessionDuration']
  end
  if hash.has_key? 'title'
    @title = hash['title']
  end
  if hash.has_key? 'transactionExpirationDateTime'
    @transaction_expiration_date_time = DateTime.parse(hash['transactionExpirationDateTime'])
  end
end

#to_hHash

Returns:

  • (Hash)


41
42
43
44
45
46
47
48
49
50
51
52
53
# File 'lib/onlinepayments/sdk/domain/redirect_payment_product5300_specific_input.rb', line 41

def to_h
  hash = super
  hash['birthCity'] = @birth_city unless @birth_city.nil?
  hash['birthCountry'] = @birth_country unless @birth_country.nil?
  hash['birthZipCode'] = @birth_zip_code unless @birth_zip_code.nil?
  hash['channel'] = @channel unless @channel.nil?
  hash['loyaltyCardNumber'] = @loyalty_card_number unless @loyalty_card_number.nil?
  hash['secondInstallmentPaymentDate'] = @second_installment_payment_date unless @second_installment_payment_date.nil?
  hash['sessionDuration'] = @session_duration unless @session_duration.nil?
  hash['title'] = @title unless @title.nil?
  hash['transactionExpirationDateTime'] = @transaction_expiration_date_time.iso8601(3) unless @transaction_expiration_date_time.nil?
  hash
end