Class: Worldline::Connect::SDK::V1::Domain::MobilePaymentProduct320SpecificInput

Inherits:
Domain::DataObject
  • Object
show all
Defined in:
lib/worldline/connect/sdk/v1/domain/mobile_payment_product320_specific_input.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Domain::DataObject

new_from_hash

Instance Attribute Details

#cardholder_nameString

Returns the current value of cardholder_name.

Returns:

  • (String)

    the current value of cardholder_name



15
16
17
# File 'lib/worldline/connect/sdk/v1/domain/mobile_payment_product320_specific_input.rb', line 15

def cardholder_name
  @cardholder_name
end

#three_d_secureWorldline::Connect::SDK::V1::Domain::GPayThreeDSecure

Returns the current value of three_d_secure.

Returns:



15
16
17
# File 'lib/worldline/connect/sdk/v1/domain/mobile_payment_product320_specific_input.rb', line 15

def three_d_secure
  @three_d_secure
end

Instance Method Details

#from_hash(hash) ⇒ Object



29
30
31
32
33
34
35
36
37
38
# File 'lib/worldline/connect/sdk/v1/domain/mobile_payment_product320_specific_input.rb', line 29

def from_hash(hash)
  super
  if hash.has_key? 'cardholderName'
    @cardholder_name = hash['cardholderName']
  end
  if hash.has_key? 'threeDSecure'
    raise TypeError, "value '%s' is not a Hash" % [hash['threeDSecure']] unless hash['threeDSecure'].is_a? Hash
    @three_d_secure = Worldline::Connect::SDK::V1::Domain::GPayThreeDSecure.new_from_hash(hash['threeDSecure'])
  end
end

#to_hHash

Returns:

  • (Hash)


22
23
24
25
26
27
# File 'lib/worldline/connect/sdk/v1/domain/mobile_payment_product320_specific_input.rb', line 22

def to_h
  hash = super
  hash['cardholderName'] = @cardholder_name unless @cardholder_name.nil?
  hash['threeDSecure'] = @three_d_secure.to_h unless @three_d_secure.nil?
  hash
end