class Concurrent::Async::AwaitDelegator

@!visibility private
Delegates synchronous, thread-safe method calls to the wrapped object.

def initialize(delegate)

Parameters:
  • delegate (AsyncDelegator) -- the object to wrap and delegate method calls to
def initialize(delegate)
  @delegate = delegate
end

def method_missing(method, *args, &block)

Raises:
  • (ArgumentError) - the given `args` do not match the arity of `method`
  • (NameError) - the object does not respond to `method` method

Returns:
  • (IVar) - the result of the method call

Parameters:
  • args (Array) -- zero or more arguments to the method
  • method (Symbol) -- the method being called
def method_missing(method, *args, &block)
  ivar = @delegate.send(method, *args, &block)
  ivar.wait
  ivar
end

def respond_to_missing?(method, include_private = false)

Parameters:
  • method (Symbol) -- the method being called
def respond_to_missing?(method, include_private = false)
  @delegate.respond_to?(method) || super
end