Class: SixSaferpay::SixPaymentPage::Initialize
- Inherits:
-
Object
- Object
- SixSaferpay::SixPaymentPage::Initialize
- Defined in:
- lib/six_saferpay/api/six_payment_page/requests/initialize.rb
Instance Attribute Summary collapse
-
#authentication ⇒ Object
Returns the value of attribute authentication.
-
#billing_address_form ⇒ Object
Returns the value of attribute billing_address_form.
-
#card_form ⇒ Object
Returns the value of attribute card_form.
-
#condition ⇒ Object
Returns the value of attribute condition.
-
#config_set ⇒ Object
Returns the value of attribute config_set.
-
#delivery_address_form ⇒ Object
Returns the value of attribute delivery_address_form.
-
#notification ⇒ Object
Returns the value of attribute notification.
-
#order ⇒ Object
Returns the value of attribute order.
-
#payer ⇒ Object
Returns the value of attribute payer.
-
#payment ⇒ Object
Returns the value of attribute payment.
-
#payment_methods ⇒ Object
Returns the value of attribute payment_methods.
-
#payment_methods_options ⇒ Object
Returns the value of attribute payment_methods_options.
-
#register_alias ⇒ Object
Returns the value of attribute register_alias.
-
#request_header ⇒ Object
Returns the value of attribute request_header.
-
#return_urls ⇒ Object
Returns the value of attribute return_urls.
-
#risk_factors ⇒ Object
Returns the value of attribute risk_factors.
-
#styling ⇒ Object
Returns the value of attribute styling.
-
#terminal_id ⇒ Object
Returns the value of attribute terminal_id.
-
#wallets ⇒ Object
Returns the value of attribute wallets.
Instance Method Summary collapse
-
#initialize(request_header: nil, config_set: nil, terminal_id: nil, payment:, payment_methods: nil, payment_methods_options: nil, authentication: nil, wallets: nil, payer: nil, register_alias: nil, return_urls: nil, notification: nil, styling: nil, billing_address_form: nil, delivery_address_form: nil, card_form: nil, condition: nil, order: nil, risk_factors: nil) ⇒ Initialize
constructor
A new instance of Initialize.
- #response_class ⇒ Object
- #to_hash ⇒ Object (also: #to_h)
- #to_json ⇒ Object
- #url ⇒ Object
Constructor Details
#initialize(request_header: nil, config_set: nil, terminal_id: nil, payment:, payment_methods: nil, payment_methods_options: nil, authentication: nil, wallets: nil, payer: nil, register_alias: nil, return_urls: nil, notification: nil, styling: nil, billing_address_form: nil, delivery_address_form: nil, card_form: nil, condition: nil, order: nil, risk_factors: nil) ⇒ Initialize
Returns a new instance of Initialize.
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 27 def initialize(request_header: nil, config_set: nil, terminal_id: nil, payment:, payment_methods: nil, payment_methods_options: nil, authentication: nil, wallets: nil, payer: nil, register_alias: nil, return_urls: nil, notification: nil, styling: nil, billing_address_form: nil, delivery_address_form: nil, card_form: nil, condition: nil, order: nil, risk_factors: nil ) @request_header = request_header || SixSaferpay::RequestHeader.new() @config_set = config_set @terminal_id = terminal_id || SixSaferpay.config.terminal_id @payment = SixSaferpay::Payment.new(**payment.to_h) if payment @payment_methods = payment_methods @payment_methods_options = SixSaferpay::PaymentMethodsOptions.new(**.to_h) if @authentication = SixSaferpay::Authentication.new(**authentication.to_h) if authentication @wallets = wallets @payer = SixSaferpay::Payer.new(**payer.to_h) if payer @register_alias = SixSaferpay::RegisterAlias.new(**register_alias.to_h) if register_alias @return_urls = return_urls || SixSaferpay::ReturnUrls.new() @notification = SixSaferpay::Notification.new(**notification.to_h) if notification @styling = SixSaferpay::Styling.new(**styling.to_h) if styling @billing_address_form = SixSaferpay::BillingAddressForm.new(**billing_address_form.to_h) if billing_address_form @delivery_address_form = SixSaferpay::DeliveryAddressForm.new(**delivery_address_form.to_h) if delivery_address_form @card_form = SixSaferpay::CardForm.new(**card_form.to_h) if card_form @condition = condition @order = SixSaferpay::Order.new(**order.to_h) if order @risk_factors = SixSaferpay::RiskFactors.new(**risk_factors.to_h) if risk_factors end |
Instance Attribute Details
#authentication ⇒ Object
Returns the value of attribute authentication.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def authentication @authentication end |
#billing_address_form ⇒ Object
Returns the value of attribute billing_address_form.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def billing_address_form @billing_address_form end |
#card_form ⇒ Object
Returns the value of attribute card_form.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def card_form @card_form end |
#condition ⇒ Object
Returns the value of attribute condition.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def condition @condition end |
#config_set ⇒ Object
Returns the value of attribute config_set.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def config_set @config_set end |
#delivery_address_form ⇒ Object
Returns the value of attribute delivery_address_form.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def delivery_address_form @delivery_address_form end |
#notification ⇒ Object
Returns the value of attribute notification.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def notification @notification end |
#order ⇒ Object
Returns the value of attribute order.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def order @order end |
#payer ⇒ Object
Returns the value of attribute payer.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def payer @payer end |
#payment ⇒ Object
Returns the value of attribute payment.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def payment @payment end |
#payment_methods ⇒ Object
Returns the value of attribute payment_methods.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def payment_methods @payment_methods end |
#payment_methods_options ⇒ Object
Returns the value of attribute payment_methods_options.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def @payment_methods_options end |
#register_alias ⇒ Object
Returns the value of attribute register_alias.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def register_alias @register_alias end |
#request_header ⇒ Object
Returns the value of attribute request_header.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def request_header @request_header end |
#return_urls ⇒ Object
Returns the value of attribute return_urls.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def return_urls @return_urls end |
#risk_factors ⇒ Object
Returns the value of attribute risk_factors.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def risk_factors @risk_factors end |
#styling ⇒ Object
Returns the value of attribute styling.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def styling @styling end |
#terminal_id ⇒ Object
Returns the value of attribute terminal_id.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def terminal_id @terminal_id end |
#wallets ⇒ Object
Returns the value of attribute wallets.
5 6 7 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 5 def wallets @wallets end |
Instance Method Details
#response_class ⇒ Object
101 102 103 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 101 def response_class SixSaferpay::SixPaymentPage::InitializeResponse end |
#to_hash ⇒ Object Also known as: to_h
68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 68 def to_hash hash = Hash.new hash.merge!(request_header: @request_header.to_h) hash.merge!(config_set: @config_set) if @config_set hash.merge!(terminal_id: @terminal_id) hash.merge!(payment: @payment.to_h) hash.merge!(payment_methods: @payment_methods) if @payment_methods hash.merge!(payment_methods_options: @payment_methods_options.to_h) if @payment_methods_options hash.merge!(authentication: @authentication.to_h) if @authentication hash.merge!(wallets: @wallets) if @wallets hash.merge!(payer: @payer.to_h) if @payer hash.merge!(register_alias: @register_alias.to_h) if @register_alias hash.merge!(return_urls: @return_urls.to_h) hash.merge!(notification: @notification.to_h) if @notification hash.merge!(styling: @styling.to_h) if @styling hash.merge!(billing_address_form: @billing_address_form.to_h) if @billing_address_form hash.merge!(delivery_address_form: @delivery_address_form.to_h) if @delivery_address_form hash.merge!(card_form: @card_form.to_h) if @card_form hash.merge!(condition: @condition) if @condition hash.merge!(order: @order.to_h) if @order hash.merge!(risk_factors: @risk_factors.to_h) if @risk_factors hash end |
#to_json ⇒ Object
93 94 95 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 93 def to_json to_hash.to_json end |
#url ⇒ Object
97 98 99 |
# File 'lib/six_saferpay/api/six_payment_page/requests/initialize.rb', line 97 def url '/Payment/v1/PaymentPage/Initialize' end |