Module: Configoro
- Defined in:
- lib/configoro/base.rb
Overview
This module handles initialization of the Configoro object, and contains some utility methods.
Defined Under Namespace
Class Method Summary (collapse)
-
+ (Object) initialize
Creates the configuration dictionary and stores it under @MyApp::Configuration@ (assuming an application named @MyApp@).
-
+ (Module) namespace
The Rails application namespace; e.g., @MyApp@ for a Rails app named @MyApp::Application@.
Class Method Details
+ (Object) initialize
Creates the configuration dictionary and stores it under @MyApp::Configuration@ (assuming an application named @MyApp@).
16 17 18 |
# File 'lib/configoro/base.rb', line 16 def self.initialize namespace.const_set :Configuration, build_hash(Rails.env) end |
+ (Module) namespace
The Rails application namespace; e.g., @MyApp@ for a Rails app named @MyApp::Application@.
9 10 11 |
# File 'lib/configoro/base.rb', line 9 def self.namespace Object.const_get Rails.application.class.to_s.split('::').first end |