lib/mutant/actor.rb in mutant-0.8.8 vs lib/mutant/actor.rb in mutant-0.8.9
- old
+ new
@@ -11,12 +11,10 @@
INSPECT = 'Mutant::Actor::Undefined'.freeze
# Object inspection
#
# @return [String]
- #
- # @api private
def inspect
INSPECT
end
end.new
@@ -28,28 +26,24 @@
#
# @param [Symbol] type
# @param [Object] payload
#
# @return [Message]
- #
- # @api private
def self.new(_type, _payload = Undefined)
super
end
end # Message
- # Binding to othersactors sender for simple RPC
+ # Binding to other actors sender for simple RPC
class Binding
include Concord.new(:mailbox, :other)
# Send message and wait for reply
#
# @param [Symbol] type
#
# @return [Object]
- #
- # @api private
def call(type)
other.call(Message.new(type, mailbox.sender))
message = mailbox.receiver.call
fail ProtocolError, "Expected #{type} but got #{message.type}" unless type.equal?(message.type)
message.payload