Class: Tasks::BaseHandler
- Inherits:
-
Object
- Object
- Tasks::BaseHandler
- Defined in:
- app/models/tasks/base_handler.rb
Overview
While many tasks have handlers included directly in the controller, we are attempting to move them out into independent models. At times these may be more tightly coupled to the controllers than is ideal, reflecting their previous unity.
Direct Known Subclasses
AddSpikedInControlHandler::Handler, SetDescriptorsHandler::Handler
Instance Attribute Summary collapse
-
#controller ⇒ Object
readonly
Returns the value of attribute controller.
-
#params ⇒ Object
readonly
Returns the value of attribute params.
-
#task ⇒ Object
readonly
Returns the value of attribute task.
-
#user ⇒ Object
readonly
Returns the value of attribute user.
Instance Method Summary collapse
-
#initialize(controller:, params:, task:, user:) ⇒ BaseHandler
constructor
A new instance of BaseHandler.
Constructor Details
#initialize(controller:, params:, task:, user:) ⇒ BaseHandler
Returns a new instance of BaseHandler.
14 15 16 17 18 19 |
# File 'app/models/tasks/base_handler.rb', line 14 def initialize(controller:, params:, task:, user:) @controller = controller @params = params @task = task @user = user end |
Instance Attribute Details
#controller ⇒ Object (readonly)
Returns the value of attribute controller.
10 11 12 |
# File 'app/models/tasks/base_handler.rb', line 10 def controller @controller end |
#params ⇒ Object (readonly)
Returns the value of attribute params.
10 11 12 |
# File 'app/models/tasks/base_handler.rb', line 10 def params @params end |
#task ⇒ Object (readonly)
Returns the value of attribute task.
10 11 12 |
# File 'app/models/tasks/base_handler.rb', line 10 def task @task end |
#user ⇒ Object (readonly)
Returns the value of attribute user.
10 11 12 |
# File 'app/models/tasks/base_handler.rb', line 10 def user @user end |