Class: SixSaferpay::PaymentMethodOptions

Inherits:
Object
  • Object
show all
Defined in:
lib/six_saferpay/models/payment_method_options.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(bankcontact: nil) ⇒ PaymentMethodOptions

Returns a new instance of PaymentMethodOptions.



6
7
8
# File 'lib/six_saferpay/models/payment_method_options.rb', line 6

def initialize(bankcontact: nil)
  @bankcontact = SixSaferpay::Bankcontact.new(**bankcontact.to_h) if bankcontact
end

Instance Attribute Details

#bankcontactObject

Returns the value of attribute bankcontact.



4
5
6
# File 'lib/six_saferpay/models/payment_method_options.rb', line 4

def bankcontact
  @bankcontact
end

Instance Method Details

#to_hashObject Also known as: to_h



10
11
12
13
14
# File 'lib/six_saferpay/models/payment_method_options.rb', line 10

def to_hash
  hash = Hash.new
  hash.merge!(bankcontact: @bankcontact.to_h) if @bankcontact
  hash
end