Class: Ribbit::Adapters::Merb
- Defined in:
- lib/ribbit/adapters/merb.rb
Defined Under Namespace
Modules: ControllerMixin, DefaultExceptionExtensions
Instance Attribute Summary
Attributes inherited from Adapter
Instance Method Summary collapse
- #activate! ⇒ Object
-
#initialize(config) ⇒ Merb
constructor
A new instance of Merb.
- #logger ⇒ Object
Methods inherited from Adapter
Constructor Details
#initialize(config) ⇒ Merb
Returns a new instance of Merb.
5 6 7 8 9 |
# File 'lib/ribbit/adapters/merb.rb', line 5 def initialize(config) super(config) config.environment_name = ::Merb.env config.project_root = ::Merb.root end |
Instance Method Details
#activate! ⇒ Object
15 16 17 18 19 20 21 22 23 |
# File 'lib/ribbit/adapters/merb.rb', line 15 def activate! ::Merb::BootLoader.after_app_loads do ::Merb::AbstractController.send(:include, ControllerMixin) if configuration.automatic? ::Merb::Dispatcher::DefaultException.send(:include, ControllerMixin) ::Merb::Dispatcher::DefaultException.send(:include, DefaultExceptionExtensions) end end end |
#logger ⇒ Object
11 12 13 |
# File 'lib/ribbit/adapters/merb.rb', line 11 def logger ::Merb.logger end |