Class: Ingenico::Direct::SDK::Domain::CreateHostedTokenizationRequest

Inherits:
Ingenico::Direct::SDK::DataObject show all
Defined in:
lib/ingenico/direct/sdk/domain/create_hosted_tokenization_request.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Ingenico::Direct::SDK::DataObject

new_from_hash

Instance Attribute Details

Returns the current value of ask_consumer_consent.

Returns:

  • (true/false)

    the current value of ask_consumer_consent



14
15
16
# File 'lib/ingenico/direct/sdk/domain/create_hosted_tokenization_request.rb', line 14

def ask_consumer_consent
  @ask_consumer_consent
end

#localeString

Returns the current value of locale.

Returns:

  • (String)

    the current value of locale



14
15
16
# File 'lib/ingenico/direct/sdk/domain/create_hosted_tokenization_request.rb', line 14

def locale
  @locale
end

#tokensString

Returns the current value of tokens.

Returns:

  • (String)

    the current value of tokens



14
15
16
# File 'lib/ingenico/direct/sdk/domain/create_hosted_tokenization_request.rb', line 14

def tokens
  @tokens
end

#variantString

Returns the current value of variant.

Returns:

  • (String)

    the current value of variant



14
15
16
# File 'lib/ingenico/direct/sdk/domain/create_hosted_tokenization_request.rb', line 14

def variant
  @variant
end

Instance Method Details

#from_hash(hash) ⇒ Object



30
31
32
33
34
35
36
# File 'lib/ingenico/direct/sdk/domain/create_hosted_tokenization_request.rb', line 30

def from_hash(hash)
  super
  @ask_consumer_consent = hash['askConsumerConsent'] if hash.key? 'askConsumerConsent'
  @locale = hash['locale'] if hash.key? 'locale'
  @tokens = hash['tokens'] if hash.key? 'tokens'
  @variant = hash['variant'] if hash.key? 'variant'
end

#to_hHash

Returns:

  • (Hash)


21
22
23
24
25
26
27
28
# File 'lib/ingenico/direct/sdk/domain/create_hosted_tokenization_request.rb', line 21

def to_h
  hash = super
  hash['askConsumerConsent'] = @ask_consumer_consent unless @ask_consumer_consent.nil?
  hash['locale'] = @locale unless @locale.nil?
  hash['tokens'] = @tokens unless @tokens.nil?
  hash['variant'] = @variant unless @variant.nil?
  hash
end