Class: Ingenico::Connect::SDK::Domain::Token::MandateSepaDirectDebitWithoutCreditor

Inherits:
Ingenico::Connect::SDK::DataObject show all
Defined in:
lib/ingenico/connect/sdk/domain/token/mandate_sepa_direct_debit_without_creditor.rb

Direct Known Subclasses

MandateSepaDirectDebitWithMandateId

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Ingenico::Connect::SDK::DataObject

new_from_hash

Instance Attribute Details

#bank_account_ibanIngenico::Connect::SDK::Domain::Definitions::BankAccountIban

Returns the current value of bank_account_iban.

Returns:



20
21
22
# File 'lib/ingenico/connect/sdk/domain/token/mandate_sepa_direct_debit_without_creditor.rb', line 20

def 
  
end

#customer_contract_identifierString

Returns the current value of customer_contract_identifier.

Returns:

  • (String)

    the current value of customer_contract_identifier



20
21
22
# File 'lib/ingenico/connect/sdk/domain/token/mandate_sepa_direct_debit_without_creditor.rb', line 20

def customer_contract_identifier
  @customer_contract_identifier
end

#debtorIngenico::Connect::SDK::Domain::Token::Debtor

Returns the current value of debtor.

Returns:



20
21
22
# File 'lib/ingenico/connect/sdk/domain/token/mandate_sepa_direct_debit_without_creditor.rb', line 20

def debtor
  @debtor
end

#is_recurringtrue/false

Returns the current value of is_recurring.

Returns:

  • (true/false)

    the current value of is_recurring



20
21
22
# File 'lib/ingenico/connect/sdk/domain/token/mandate_sepa_direct_debit_without_creditor.rb', line 20

def is_recurring
  @is_recurring
end

#mandate_approvalIngenico::Connect::SDK::Domain::Token::MandateApproval

Returns the current value of mandate_approval.

Returns:



20
21
22
# File 'lib/ingenico/connect/sdk/domain/token/mandate_sepa_direct_debit_without_creditor.rb', line 20

def mandate_approval
  @mandate_approval
end

#pre_notificationString

Returns the current value of pre_notification.

Returns:

  • (String)

    the current value of pre_notification



20
21
22
# File 'lib/ingenico/connect/sdk/domain/token/mandate_sepa_direct_debit_without_creditor.rb', line 20

def pre_notification
  @pre_notification
end

Instance Method Details

#from_hash(hash) ⇒ Object



46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# File 'lib/ingenico/connect/sdk/domain/token/mandate_sepa_direct_debit_without_creditor.rb', line 46

def from_hash(hash)
  super
  if hash.has_key? 'bankAccountIban'
    raise TypeError, "value '%s' is not a Hash" % [hash['bankAccountIban']] unless hash['bankAccountIban'].is_a? Hash
     = Ingenico::Connect::SDK::Domain::Definitions::BankAccountIban.new_from_hash(hash['bankAccountIban'])
  end
  if hash.has_key? 'customerContractIdentifier'
    @customer_contract_identifier = hash['customerContractIdentifier']
  end
  if hash.has_key? 'debtor'
    raise TypeError, "value '%s' is not a Hash" % [hash['debtor']] unless hash['debtor'].is_a? Hash
    @debtor = Ingenico::Connect::SDK::Domain::Token::Debtor.new_from_hash(hash['debtor'])
  end
  if hash.has_key? 'isRecurring'
    @is_recurring = hash['isRecurring']
  end
  if hash.has_key? 'mandateApproval'
    raise TypeError, "value '%s' is not a Hash" % [hash['mandateApproval']] unless hash['mandateApproval'].is_a? Hash
    @mandate_approval = Ingenico::Connect::SDK::Domain::Token::MandateApproval.new_from_hash(hash['mandateApproval'])
  end
  if hash.has_key? 'preNotification'
    @pre_notification = hash['preNotification']
  end
end

#to_hHash

Returns:

  • (Hash)


35
36
37
38
39
40
41
42
43
44
# File 'lib/ingenico/connect/sdk/domain/token/mandate_sepa_direct_debit_without_creditor.rb', line 35

def to_h
  hash = super
  hash['bankAccountIban'] = .to_h unless .nil?
  hash['customerContractIdentifier'] = @customer_contract_identifier unless @customer_contract_identifier.nil?
  hash['debtor'] = @debtor.to_h unless @debtor.nil?
  hash['isRecurring'] = @is_recurring unless @is_recurring.nil?
  hash['mandateApproval'] = @mandate_approval.to_h unless @mandate_approval.nil?
  hash['preNotification'] = @pre_notification unless @pre_notification.nil?
  hash
end