Class: XFTP::Configuration
- Inherits:
-
Object
- Object
- XFTP::Configuration
- Includes:
- ActiveSupport::Configurable
- Defined in:
- lib/configuration.rb
Overview
Provides a way to store and retrive configuration options
Class Method Summary collapse
- .config_accessor(*names) ⇒ Object
-
.old_config_accessor ⇒ Object
HACK: This is required to smooth a future transition to activesupport 4.x Since 3-2’s config_accessor doesn’t take a block or provide an option to set the default value of a config.
Class Method Details
.config_accessor(*names) ⇒ Object
16 17 18 19 20 21 22 23 |
# File 'lib/configuration.rb', line 16 def config_accessor(*names) old_config_accessor(*names) return unless block_given? names.each do |name| send("#{name}=", yield) end end |
.old_config_accessor ⇒ Object
HACK: This is required to smooth a future transition to activesupport 4.x Since 3-2’s config_accessor doesn’t take a block or provide an option to set the default value of a config.
14 |
# File 'lib/configuration.rb', line 14 alias_method :old_config_accessor, :config_accessor |