Class: Dapp::Deployment::Config::Directive::Job
- Inherits:
-
Base
- Object
- Config::Directive::Base
- Base
- Dapp::Deployment::Config::Directive::Job
- Defined in:
- lib/dapp/deployment/config/directive/job.rb
Instance Attribute Summary collapse
-
#_dimg ⇒ Object
readonly
Returns the value of attribute _dimg.
-
#_run ⇒ Object
readonly
Returns the value of attribute _run.
Instance Method Summary collapse
- #dimg(name) ⇒ Object
- #empty? ⇒ Boolean
-
#initialize(*args) ⇒ Job
constructor
A new instance of Job.
- #run(*args) ⇒ Object
Methods inherited from Base
Methods inherited from Config::Directive::Base
Constructor Details
#initialize(*args) ⇒ Job
Returns a new instance of Job.
8 9 10 11 |
# File 'lib/dapp/deployment/config/directive/job.rb', line 8 def initialize(*args) super @_run = [] end |
Instance Attribute Details
#_dimg ⇒ Object (readonly)
Returns the value of attribute _dimg.
6 7 8 |
# File 'lib/dapp/deployment/config/directive/job.rb', line 6 def _dimg @_dimg end |
#_run ⇒ Object (readonly)
Returns the value of attribute _run.
6 7 8 |
# File 'lib/dapp/deployment/config/directive/job.rb', line 6 def _run @_run end |
Instance Method Details
#dimg(name) ⇒ Object
17 18 19 |
# File 'lib/dapp/deployment/config/directive/job.rb', line 17 def dimg(name) sub_directive_eval { @_dimg = name } end |
#empty? ⇒ Boolean
21 22 23 |
# File 'lib/dapp/deployment/config/directive/job.rb', line 21 def empty? _run.empty? && _dimg.nil? end |
#run(*args) ⇒ Object
13 14 15 |
# File 'lib/dapp/deployment/config/directive/job.rb', line 13 def run(*args) sub_directive_eval { @_run.concat(args.flatten) } end |