Class: Idcf::Cli::Service::Ilb::CheckJob
- Defined in:
- lib/idcf/cli/service/ilb/check_job.rb
Overview
check_job
Constant Summary
Constants inherited from Base
Base::ARG_TYPE_OPT, Base::ARG_TYPE_REQ, Base::ARG_TYPE_REST, Base::HELP_FORMAT
Instance Attribute Summary collapse
-
#api ⇒ Object
readonly
Returns the value of attribute api.
Attributes inherited from Base
#last_command, #last_command_args
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Base
#between_param?, #cli_error, #initialize, make_param_s, #method_option_cnt, #method_rest?, option, reset, valid_params
Methods included from Lib::Include::RecurringCalling
Constructor Details
This class inherits a constructor from Idcf::Cli::Service::Base
Instance Attribute Details
#api ⇒ Object (readonly)
Returns the value of attribute api.
9 10 11 |
# File 'lib/idcf/cli/service/ilb/check_job.rb', line 9 def api @api end |
Class Method Details
.description ⇒ Object
12 13 14 |
# File 'lib/idcf/cli/service/ilb/check_job.rb', line 12 def description 'Check job result' end |
Instance Method Details
#do(api, _o, job_id) ⇒ Object
do
22 23 24 25 26 27 28 |
# File 'lib/idcf/cli/service/ilb/check_job.rb', line 22 def do(api, _o, job_id) @api = api job = recurring_calling(:find, [job_id], &:present?) return nil if job['method'].casecmp('delete').zero? raise Idcf::Cli::Error::ApiError.new(@api.raw), 'Job Timeout.' if job.nil? true end |