class Ingenico::Direct::SDK::Domain::HostedCheckoutSpecificInput

@attr [true/false] is_recurring @attr [String] locale @attr [Ingenico::Direct::SDK::Domain::PaymentProductFiltersHostedCheckout] payment_product_filters @attr [String] return_url @attr [Integer] session_timeout @attr [true/false] show_result_page @attr [String] tokens @attr [String] variant

Attributes

is_recurring[RW]
locale[RW]
payment_product_filters[RW]
return_url[RW]
session_timeout[RW]
show_result_page[RW]
tokens[RW]
variant[RW]

Public Instance Methods

from_hash(hash) click to toggle source
# File lib/ingenico/direct/sdk/domain/hosted_checkout_specific_input.rb, line 43
def from_hash(hash)
  super
  @is_recurring = hash['isRecurring'] if hash.key? 'isRecurring'
  @locale = hash['locale'] if hash.key? 'locale'
  if hash.key? 'paymentProductFilters'
    raise TypeError, "value '%s' is not a Hash" % [hash['paymentProductFilters']] unless hash['paymentProductFilters'].is_a? Hash
    @payment_product_filters = Ingenico::Direct::SDK::Domain::PaymentProductFiltersHostedCheckout.new_from_hash(hash['paymentProductFilters'])
  end
  @return_url = hash['returnUrl'] if hash.key? 'returnUrl'
  @session_timeout = hash['sessionTimeout'] if hash.key? 'sessionTimeout'
  @show_result_page = hash['showResultPage'] if hash.key? 'showResultPage'
  @tokens = hash['tokens'] if hash.key? 'tokens'
  @variant = hash['variant'] if hash.key? 'variant'
end
to_h() click to toggle source

@return (Hash)

Calls superclass method Ingenico::Direct::SDK::DataObject#to_h
# File lib/ingenico/direct/sdk/domain/hosted_checkout_specific_input.rb, line 30
def to_h
  hash = super
  hash['isRecurring'] = @is_recurring unless @is_recurring.nil?
  hash['locale'] = @locale unless @locale.nil?
  hash['paymentProductFilters'] = @payment_product_filters.to_h if @payment_product_filters
  hash['returnUrl'] = @return_url unless @return_url.nil?
  hash['sessionTimeout'] = @session_timeout unless @session_timeout.nil?
  hash['showResultPage'] = @show_result_page unless @show_result_page.nil?
  hash['tokens'] = @tokens unless @tokens.nil?
  hash['variant'] = @variant unless @variant.nil?
  hash
end