class Worker
Public Class Methods
new(executor)
click to toggle source
Calls superclass method
# File doc/actor.rb, line 10 def initialize(executor) super() @executor = executor end
Public Instance Methods
on_message(message)
click to toggle source
# File doc/actor.rb, line 15 def on_message(message) match message, Work.(~any, ~any) >-> key, work do @executor.tell Finished[key, work.call, self] end end