Class: Taskinator::Executor
- Inherits:
-
Object
- Object
- Taskinator::Executor
- Defined in:
- lib/taskinator/executor.rb
Instance Attribute Summary collapse
-
#definition ⇒ Object
readonly
Returns the value of attribute definition.
-
#task ⇒ Object
readonly
Returns the value of attribute task.
Instance Method Summary collapse
-
#initialize(definition, task = nil) ⇒ Executor
constructor
A new instance of Executor.
Constructor Details
#initialize(definition, task = nil) ⇒ Executor
Returns a new instance of Executor.
7 8 9 10 11 12 13 14 |
# File 'lib/taskinator/executor.rb', line 7 def initialize(definition, task=nil) @definition = definition @task = task # include the module into the eigen class, so it is only for this instance eigen = class << self; self; end eigen.send :include, definition end |
Instance Attribute Details
#definition ⇒ Object (readonly)
Returns the value of attribute definition.
4 5 6 |
# File 'lib/taskinator/executor.rb', line 4 def definition @definition end |
#task ⇒ Object (readonly)
Returns the value of attribute task.
5 6 7 |
# File 'lib/taskinator/executor.rb', line 5 def task @task end |