Class: Celluloid::SystemEvent::LinkingEvent

Inherits:
Celluloid::SystemEvent show all
Defined in:
lib/celluloid/system_events.rb

Direct Known Subclasses

LinkingRequest, LinkingResponse

Instance Method Summary collapse

Methods inherited from Celluloid::SystemEvent

handle, handler

Constructor Details

#initialize(actor, type) ⇒ LinkingEvent

Shared initializer for LinkingRequest and LinkingResponse

Raises:

  • (ArgumentError)


41
42
43
44
45
# File 'lib/celluloid/system_events.rb', line 41

def initialize(actor, type)
  @actor = actor
  @type = type.to_sym
  raise ArgumentError, "type must be link or unlink" unless %i[link unlink].include?(@type)
end