Class: FirstGiving::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/firstgiving.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



17
18
19
20
21
22
# File 'lib/firstgiving.rb', line 17

def initialize
  self.application_key = nil
  self.security_token  = nil
  self.options         = {}
  set_defaults
end

Instance Attribute Details

#application_keyObject

Returns the value of attribute application_key.



15
16
17
# File 'lib/firstgiving.rb', line 15

def application_key
  @application_key
end

#optionsObject

Returns the value of attribute options.



15
16
17
# File 'lib/firstgiving.rb', line 15

def options
  @options
end

#security_tokenObject

Returns the value of attribute security_token.



15
16
17
# File 'lib/firstgiving.rb', line 15

def security_token
  @security_token
end

Instance Method Details

#set_defaultsObject



24
25
26
27
28
29
# File 'lib/firstgiving.rb', line 24

def set_defaults
  options[:verbose] ||= false
  options[:read_timeout] ||= 30
  options[:use_ssl] ||= false
  options[:use_staging] ||= true
end