Module: ActiveInteraction::Runnable::ClassMethods
- Defined in:
- lib/active_interaction/concerns/runnable.rb
Overview
rubocop:disable Style/Documentation
Instance Method Summary collapse
Instance Method Details
#new ⇒ Object
97 98 99 100 101 102 103 104 105 106 |
# File 'lib/active_interaction/concerns/runnable.rb', line 97 def new(*) super.tap do |instance| { :@_interaction_errors => Errors.new(instance), :@_interaction_result => nil }.each do |symbol, obj| instance.instance_variable_set(symbol, obj) end end end |
#run(*args) ⇒ Runnable
111 112 113 |
# File 'lib/active_interaction/concerns/runnable.rb', line 111 def run(*args) new(*args).tap { |instance| instance.send(:run) } end |
#run!(*args) ⇒ Object
120 121 122 |
# File 'lib/active_interaction/concerns/runnable.rb', line 120 def run!(*args) new(*args).send(:run!) end |