Class: Worldline::Connect::SDK::V1::Domain::GetIINDetailsRequest

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Domain::DataObject

new_from_hash

Instance Attribute Details

#binString

Returns the current value of bin.

Returns:

  • (String)

    the current value of bin



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

def bin
  @bin
end

#payment_contextWorldline::Connect::SDK::V1::Domain::PaymentContext

Returns the current value of payment_context.

Returns:



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

def payment_context
  @payment_context
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/get_iin_details_request.rb', line 29

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

#to_hHash

Returns:

  • (Hash)


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

def to_h
  hash = super
  hash['bin'] = @bin unless @bin.nil?
  hash['paymentContext'] = @payment_context.to_h unless @payment_context.nil?
  hash
end