Module: MollieNLIDeal::Config

Defined in:
lib/mollienl-ideal/config.rb

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.partner_idObject

partner_id = numeric mollie partner id report_url = url mollie calls to report transaction status return_url = url Mollie redirects to after the transaction test_mode = true/false Test mode parameter for Mollie.nl



8
9
10
# File 'lib/mollienl-ideal/config.rb', line 8

def partner_id
  @partner_id
end

.report_urlObject

partner_id = numeric mollie partner id report_url = url mollie calls to report transaction status return_url = url Mollie redirects to after the transaction test_mode = true/false Test mode parameter for Mollie.nl



8
9
10
# File 'lib/mollienl-ideal/config.rb', line 8

def report_url
  @report_url
end

.return_urlObject

partner_id = numeric mollie partner id report_url = url mollie calls to report transaction status return_url = url Mollie redirects to after the transaction test_mode = true/false Test mode parameter for Mollie.nl



8
9
10
# File 'lib/mollienl-ideal/config.rb', line 8

def return_url
  @return_url
end

.test_modeObject

partner_id = numeric mollie partner id report_url = url mollie calls to report transaction status return_url = url Mollie redirects to after the transaction test_mode = true/false Test mode parameter for Mollie.nl



8
9
10
# File 'lib/mollienl-ideal/config.rb', line 8

def test_mode
  @test_mode
end

Class Method Details

.init!Object



10
11
12
13
14
15
16
17
# File 'lib/mollienl-ideal/config.rb', line 10

def init!
  @defaults = {
    :@partner_id => nil,
    :@report_url => nil,
    :@return_url => nil,
    :@test_mode => false
  }
end

.reset!Object



19
20
21
# File 'lib/mollienl-ideal/config.rb', line 19

def reset!
  @defaults.each { |k, v| instance_variable_set(k, v) }
end

.update!Object



23
24
25
26
27
# File 'lib/mollienl-ideal/config.rb', line 23

def update!
  @defaults.each do |k, v| 
    instance_variable_set(k, v) unless instance_variable_defined(k)
  end
end