Class: Worldline::Connect::SDK::V1::Domain::NonSepaDirectDebitPaymentMethodSpecificInput

Inherits:
AbstractPaymentMethodSpecificInput show all
Defined in:
lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb

Instance Attribute Summary collapse

Attributes inherited from AbstractPaymentMethodSpecificInput

#payment_product_id

Instance Method Summary collapse

Methods inherited from Domain::DataObject

new_from_hash

Instance Attribute Details

#date_collectString

Returns the current value of date_collect.

Returns:

  • (String)

    the current value of date_collect



23
24
25
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 23

def date_collect
  @date_collect
end

#direct_debit_textString

Returns the current value of direct_debit_text.

Returns:

  • (String)

    the current value of direct_debit_text



23
24
25
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 23

def direct_debit_text
  @direct_debit_text
end

#is_recurringtrue/false

Returns the current value of is_recurring.

Returns:

  • (true/false)

    the current value of is_recurring



23
24
25
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 23

def is_recurring
  @is_recurring
end

#payment_product705_specific_inputWorldline::Connect::SDK::V1::Domain::NonSepaDirectDebitPaymentProduct705SpecificInput

Returns the current value of payment_product705_specific_input.

Returns:



23
24
25
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 23

def payment_product705_specific_input
  @payment_product705_specific_input
end

#payment_product730_specific_inputWorldline::Connect::SDK::V1::Domain::NonSepaDirectDebitPaymentProduct730SpecificInput

Returns the current value of payment_product730_specific_input.

Returns:



23
24
25
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 23

def payment_product730_specific_input
  @payment_product730_specific_input
end

#recurring_payment_sequence_indicatorString

Returns the current value of recurring_payment_sequence_indicator.

Returns:

  • (String)

    the current value of recurring_payment_sequence_indicator



23
24
25
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 23

def recurring_payment_sequence_indicator
  @recurring_payment_sequence_indicator
end

#requires_approvaltrue/false

Returns the current value of requires_approval.

Returns:

  • (true/false)

    the current value of requires_approval



23
24
25
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 23

def requires_approval
  @requires_approval
end

#tokenString

Returns the current value of token.

Returns:

  • (String)

    the current value of token



23
24
25
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 23

def token
  @token
end

#tokenizetrue/false

Returns the current value of tokenize.

Returns:

  • (true/false)

    the current value of tokenize



23
24
25
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 23

def tokenize
  @tokenize
end

Instance Method Details

#from_hash(hash) ⇒ Object



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
85
86
87
88
89
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 58

def from_hash(hash)
  super
  if hash.has_key? 'dateCollect'
    @date_collect = hash['dateCollect']
  end
  if hash.has_key? 'directDebitText'
    @direct_debit_text = hash['directDebitText']
  end
  if hash.has_key? 'isRecurring'
    @is_recurring = hash['isRecurring']
  end
  if hash.has_key? 'paymentProduct705SpecificInput'
    raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct705SpecificInput']] unless hash['paymentProduct705SpecificInput'].is_a? Hash
    @payment_product705_specific_input = Worldline::Connect::SDK::V1::Domain::NonSepaDirectDebitPaymentProduct705SpecificInput.new_from_hash(hash['paymentProduct705SpecificInput'])
  end
  if hash.has_key? 'paymentProduct730SpecificInput'
    raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct730SpecificInput']] unless hash['paymentProduct730SpecificInput'].is_a? Hash
    @payment_product730_specific_input = Worldline::Connect::SDK::V1::Domain::NonSepaDirectDebitPaymentProduct730SpecificInput.new_from_hash(hash['paymentProduct730SpecificInput'])
  end
  if hash.has_key? 'recurringPaymentSequenceIndicator'
    @recurring_payment_sequence_indicator = hash['recurringPaymentSequenceIndicator']
  end
  if hash.has_key? 'requiresApproval'
    @requires_approval = hash['requiresApproval']
  end
  if hash.has_key? 'token'
    @token = hash['token']
  end
  if hash.has_key? 'tokenize'
    @tokenize = hash['tokenize']
  end
end

#to_hHash

Returns:

  • (Hash)


44
45
46
47
48
49
50
51
52
53
54
55
56
# File 'lib/worldline/connect/sdk/v1/domain/non_sepa_direct_debit_payment_method_specific_input.rb', line 44

def to_h
  hash = super
  hash['dateCollect'] = @date_collect unless @date_collect.nil?
  hash['directDebitText'] = @direct_debit_text unless @direct_debit_text.nil?
  hash['isRecurring'] = @is_recurring unless @is_recurring.nil?
  hash['paymentProduct705SpecificInput'] = @payment_product705_specific_input.to_h unless @payment_product705_specific_input.nil?
  hash['paymentProduct730SpecificInput'] = @payment_product730_specific_input.to_h unless @payment_product730_specific_input.nil?
  hash['recurringPaymentSequenceIndicator'] = @recurring_payment_sequence_indicator unless @recurring_payment_sequence_indicator.nil?
  hash['requiresApproval'] = @requires_approval unless @requires_approval.nil?
  hash['token'] = @token unless @token.nil?
  hash['tokenize'] = @tokenize unless @tokenize.nil?
  hash
end