Sha256: 1584a3f60560e319d7018a6ee5f0683bec535f4ffc3ed268aad19bbac7fe2bfa

Contents?: true

Size: 409 Bytes

Versions: 2

Compression:

Stored size: 409 Bytes

Contents

# -*- coding: utf-8 -*-
require "pb_actor/version"

module PbActor
  class << self
    def included base
      base.send :extend, ClassMethods
    end
  end

  module ClassMethods
    def new *args, &blk
      origin = allocate
      proxy = Proxy.new origin
      proxy.async.send :initialize, *args, &blk
      proxy
    end
  end

  class DeadActorError < StandardError
  end
end

require "pb_actor/proxy"

Version data entries

2 entries across 2 versions & 1 rubygems

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