Class: Reactor::Plans::UpdateJob
Constant Summary
Constants inherited
from CommonJob
CommonJob::ALLOWED_PARAMS
Instance Method Summary
collapse
Methods inherited from CommonJob
#set
Methods included from Prepared
#error, #separate_arguments
Constructor Details
#initialize(*args) ⇒ UpdateJob
Returns a new instance of UpdateJob.
7
8
9
10
11
12
|
# File 'lib/reactor/plans/update_job.rb', line 7
def initialize(*args)
super()
(name,), options = separate_arguments(*args)
@name = name || options[:name]
end
|
Instance Method Details
#migrate! ⇒ Object
21
22
23
24
|
# File 'lib/reactor/plans/update_job.rb', line 21
def migrate!
job = Reactor::Cm::Job.get(@name)
migrate_params!(job)
end
|
#prepapre! ⇒ Object
14
15
16
17
18
19
|
# File 'lib/reactor/plans/update_job.rb', line 14
def prepapre!
error("name is nil") if @name.nil?
error("job #{@name} not found") unless Reactor::Cm::Job.exists?(@name)
prepare_params!(nil)
end
|