Class: Citrus::Components::Session
- Defined in:
- lib/citrus/components/session.rb
Overview
Session
Instance Attribute Summary collapse
-
#service ⇒ Object
readonly
Returns the value of attribute service.
Instance Method Summary collapse
-
#initialize(app, args = {}) ⇒ Session
constructor
Initialize the component.
-
#method_missing(name, *args, &block) ⇒ Object
Proxy for connection service.
Constructor Details
#initialize(app, args = {}) ⇒ Session
Initialize the component
25 26 27 28 29 30 31 |
# File 'lib/citrus/components/session.rb', line 25 def initialize app, args={} @app = app @service = Common::Service::SessionService.new args this = self @app.define_singleton_method :session_service, proc{ this } end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args, &block) ⇒ Object
Proxy for connection service
36 37 38 |
# File 'lib/citrus/components/session.rb', line 36 def method_missing name, *args, &block @service.send name, *args, &block end |
Instance Attribute Details
#service ⇒ Object (readonly)
Returns the value of attribute service.
19 20 21 |
# File 'lib/citrus/components/session.rb', line 19 def service @service end |