class Concurrent::SimpleActorRef

def initialize(actor, opts = {})

def initialize(actor, opts = {})
  @actor           = actor
  @mutex           = Mutex.new
  @one_by_one      = OneByOne.new
  @executor        = OptionsParser::get_executor_from(opts)
  @stop_event      = Event.new
  @reset_on_error  = opts.fetch(:reset_on_error, true)
  @exception_class = opts.fetch(:rescue_exception, false) ? Exception : StandardError
  @args            = opts.fetch(:args, []) if @reset_on_error
  @actor.define_singleton_method(:shutdown, &method(:set_stop_event))
  @actor.on_start
end