Class: Ingenico::Direct::SDK::Domain::GetIINDetailsRequest
- Inherits:
-
Ingenico::Direct::SDK::DataObject
- Object
- Ingenico::Direct::SDK::DataObject
- Ingenico::Direct::SDK::Domain::GetIINDetailsRequest
- Defined in:
- lib/ingenico/direct/sdk/domain/get_iin_details_request.rb
Instance Attribute Summary collapse
-
#bin ⇒ String
The current value of bin.
-
#payment_context ⇒ Ingenico::Direct::SDK::Domain::PaymentContext
The current value of payment_context.
Instance Method Summary collapse
Methods inherited from Ingenico::Direct::SDK::DataObject
Instance Attribute Details
#bin ⇒ String
Returns the current value of bin.
13 14 15 |
# File 'lib/ingenico/direct/sdk/domain/get_iin_details_request.rb', line 13 def bin @bin end |
#payment_context ⇒ Ingenico::Direct::SDK::Domain::PaymentContext
Returns the current value of payment_context.
13 14 15 |
# File 'lib/ingenico/direct/sdk/domain/get_iin_details_request.rb', line 13 def payment_context @payment_context end |
Instance Method Details
#from_hash(hash) ⇒ Object
25 26 27 28 29 30 31 32 |
# File 'lib/ingenico/direct/sdk/domain/get_iin_details_request.rb', line 25 def from_hash(hash) super @bin = hash['bin'] if hash.key? 'bin' if hash.key? 'paymentContext' raise TypeError, "value '%s' is not a Hash" % [hash['paymentContext']] unless hash['paymentContext'].is_a? Hash @payment_context = Ingenico::Direct::SDK::Domain::PaymentContext.new_from_hash(hash['paymentContext']) end end |
#to_h ⇒ Hash
18 19 20 21 22 23 |
# File 'lib/ingenico/direct/sdk/domain/get_iin_details_request.rb', line 18 def to_h hash = super hash['bin'] = @bin unless @bin.nil? hash['paymentContext'] = @payment_context.to_h if @payment_context hash end |