Class: Proletariat::Actor

Inherits:
Concurrent::Actor::RestartingContext
  • Object
show all
Includes:
ActorCommon
Defined in:
lib/proletariat/concurrency/actor.rb

Overview

Public: Interface abstraction for Concurrent::Actor.

Instance Method Summary collapse

Methods included from ActorCommon

included, #on_event

Instance Method Details

#on_message(message) ⇒ Object



8
9
10
11
12
13
14
# File 'lib/proletariat/concurrency/actor.rb', line 8

def on_message(message)
  if respond_to?(:work_method)
    send work_method, message
  else
    work message
  end
end