Class: Credigy::Configuration
- Inherits:
-
Object
- Object
- Credigy::Configuration
- Defined in:
- lib/credigy/config.rb
Instance Attribute Summary collapse
-
#env ⇒ Object
Returns the value of attribute env.
-
#verbose ⇒ Object
Returns the value of attribute verbose.
- #wsdl ⇒ Object
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #production_env? ⇒ Boolean
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
15 16 17 18 |
# File 'lib/credigy/config.rb', line 15 def initialize @verbose = false @env = :dev end |
Instance Attribute Details
#env ⇒ Object
Returns the value of attribute env.
12 13 14 |
# File 'lib/credigy/config.rb', line 12 def env @env end |
#verbose ⇒ Object
Returns the value of attribute verbose.
12 13 14 |
# File 'lib/credigy/config.rb', line 12 def verbose @verbose end |
#wsdl ⇒ Object
24 25 26 27 28 29 30 31 32 |
# File 'lib/credigy/config.rb', line 24 def wsdl return @wsdl if @wsdl if production_env? 'https://www.credigy.com.br/CredigyWSP/CredigyAgenciesWSS.asmx?WSDL'.freeze else 'https://www.credigy.com.br/CredigyWST/CredigyAgenciesWSS.asmx?WSDL'.freeze end end |
Instance Method Details
#production_env? ⇒ Boolean
20 21 22 |
# File 'lib/credigy/config.rb', line 20 def production_env? env == :production end |