Class: Worldline::Acquiring::SDK::V1::Domain::InitialCardOnFileData

Inherits:
Domain::DataObject show all
Defined in:
lib/worldline/acquiring/sdk/v1/domain/initial_card_on_file_data.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Domain::DataObject

new_from_hash

Instance Attribute Details

#future_useString

Returns the current value of future_use.

Returns:

  • (String)

    the current value of future_use



13
14
15
# File 'lib/worldline/acquiring/sdk/v1/domain/initial_card_on_file_data.rb', line 13

def future_use
  @future_use
end

#transaction_typeString

Returns the current value of transaction_type.

Returns:

  • (String)

    the current value of transaction_type



13
14
15
# File 'lib/worldline/acquiring/sdk/v1/domain/initial_card_on_file_data.rb', line 13

def transaction_type
  @transaction_type
end

Instance Method Details

#from_hash(hash) ⇒ Object



27
28
29
30
31
32
33
34
35
# File 'lib/worldline/acquiring/sdk/v1/domain/initial_card_on_file_data.rb', line 27

def from_hash(hash)
  super
  if hash.has_key? 'futureUse'
    @future_use = hash['futureUse']
  end
  if hash.has_key? 'transactionType'
    @transaction_type = hash['transactionType']
  end
end

#to_hHash

Returns:

  • (Hash)


20
21
22
23
24
25
# File 'lib/worldline/acquiring/sdk/v1/domain/initial_card_on_file_data.rb', line 20

def to_h
  hash = super
  hash['futureUse'] = @future_use unless @future_use.nil?
  hash['transactionType'] = @transaction_type unless @transaction_type.nil?
  hash
end