Sha256: d55092a5f69e4aa9326975820bbf95b302bf2f97d9cfb981102813cacfc65fec

Contents?: true

Size: 338 Bytes

Versions: 1

Compression:

Stored size: 338 Bytes

Contents

module PbActor
  module Message
    class << self
      def send msg, wr
        Marshal.dump(msg, wr)
      rescue Errno::EPIPE => e
        raise DeadActorError, 'dead actor call'
      end

      def recv rd
        Marshal.load rd
      rescue EOFError => e
        raise DeadActorError, 'dead actor call'
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
pb_actor-0.0.4 lib/pb_actor/message.rb