Class: ForemanTasksCore::TaskLauncher::Single

Inherits:
Abstract
  • Object
show all
Defined in:
lib/foreman_tasks_core/task_launcher/single.rb

Instance Attribute Summary

Attributes inherited from Abstract

#callback, #options, #results, #world

Instance Method Summary collapse

Methods inherited from Abstract

#initialize

Constructor Details

This class inherits a constructor from ForemanTasksCore::TaskLauncher::Abstract

Instance Method Details

#launch!(input) ⇒ Object

{ :action_class => “MyActionClass”, :action_input => {} }



5
6
7
8
9
10
11
# File 'lib/foreman_tasks_core/task_launcher/single.rb', line 5

def launch!(input)
  triggered = trigger(options[:parent],
                      action_class(input),
                      with_callback(input.fetch('action_input', {})))
  @results = format_result(triggered)
  triggered
end