Class: Swee::Config
Defined Under Namespace
Classes: AppConfig, AppPluginConfig, BaseConfig, DbConfig, ServerConfig
Instance Attribute Summary collapse
-
#app ⇒ Object
Returns the value of attribute app.
-
#app_plugin ⇒ Object
Returns the value of attribute app_plugin.
-
#db ⇒ Object
Returns the value of attribute db.
-
#server ⇒ Object
Returns the value of attribute server.
Instance Method Summary collapse
- #default_config!(options) ⇒ Object
-
#initialize ⇒ Config
constructor
A new instance of Config.
Constructor Details
#initialize ⇒ Config
Returns a new instance of Config.
108 109 110 111 112 113 |
# File 'lib/swee/config.rb', line 108 def initialize @server = ServerConfig.new @app = AppConfig.new @db = DbConfig.new # @plugin = AppPluginConfig.new end |
Instance Attribute Details
#app ⇒ Object
Returns the value of attribute app.
107 108 109 |
# File 'lib/swee/config.rb', line 107 def app @app end |
#app_plugin ⇒ Object
Returns the value of attribute app_plugin.
107 108 109 |
# File 'lib/swee/config.rb', line 107 def app_plugin @app_plugin end |
#db ⇒ Object
Returns the value of attribute db.
107 108 109 |
# File 'lib/swee/config.rb', line 107 def db @db end |
#server ⇒ Object
Returns the value of attribute server.
107 108 109 |
# File 'lib/swee/config.rb', line 107 def server @server end |
Instance Method Details
#default_config!(options) ⇒ Object
115 116 117 |
# File 'lib/swee/config.rb', line 115 def default_config! [@server,@app,@db].each { |cfg| cfg.default_config! } end |