Module: Trinidad::Lifecycle::WebApp::Shared
Overview
Shared web application lifecycle hook, does #configure before the context starts.
Instance Attribute Summary collapse
-
#web_app ⇒ Object
(also: #webapp)
readonly
Returns the value of attribute web_app.
Instance Method Summary collapse
- #before_start(event) ⇒ Object
-
#configure(context) ⇒ Object
Configure the web application before it’s started.
- #initialize(web_app) ⇒ Object
Instance Attribute Details
#web_app ⇒ Object (readonly) Also known as: webapp
Returns the value of attribute web_app.
8 9 10 |
# File 'lib/trinidad/lifecycle/web_app/shared.rb', line 8 def web_app @web_app end |
Instance Method Details
#before_start(event) ⇒ Object
16 17 18 19 |
# File 'lib/trinidad/lifecycle/web_app/shared.rb', line 16 def before_start(event) super configure(event.lifecycle) end |
#configure(context) ⇒ Object
Configure the web application before it’s started.
22 23 24 25 |
# File 'lib/trinidad/lifecycle/web_app/shared.rb', line 22 def configure(context) remove_defaults(context) configure_logging(context) end |
#initialize(web_app) ⇒ Object
11 12 13 |
# File 'lib/trinidad/lifecycle/web_app/shared.rb', line 11 def initialize(web_app) @web_app = web_app end |