Invokes the method of the current object and if synchronous, fetches the next.
186836
function execute() {
        var listeners,
            async = isAsync(bench);

        if (async) {
          // Use `getNext` as the first listener.
          bench.on('complete', getNext);
          listeners = bench.events.complete;
          listeners.splice(0, 0, listeners.pop());
        }
        // Execute method.
        result[index] = _.isFunction(bench && bench[name]) ? bench[name].apply(bench, args) : undefined;
        // If synchronous return `true` until finished.
        return !async && getNext();
      }
314678
def next(self):
        
        return self.iterator.next(task=self.task, timeout=self.timeout,
                                                    block=self.block)
822461
function nextMiddleware() {
		// Get the next middleware
		var next = _mappings[middleware.names[middleware.index++]];

		// If there is middleware, then invoke it, binding request
		if ( next ) $injector.invoke(next, request);
	}
1307719
private void nextQueue()
  {
    if(super.hasNext())
    {      
      do
      {
        if(_currentSubIterator != null) _currentSubIterator.finished();
        _currentSubIterator = null;
        _currentQueue = (SIMPQueueControllable) super.next();
        
        try
        {
          _currentSubIterator = _currentQueue.getRemoteQueuePointIterator();
        }
        catch (SIMPException e) 
        {
          // No FFDC code needed
        
          if (tc.isDebugEnabled())
            SibTr.exception(tc, e);          
        }       
      }
      // Retry if we failed to get an iterator, that iterator does not
      // have any remote queue points in it and we have more queues available.
      while((_currentSubIterator == null || !_currentSubIterator.hasNext())
        && super.hasNext());
    }
    else
    {
      _currentQueue = null;
      if(_currentSubIterator != null) _currentSubIterator.finished();
      _currentSubIterator = null;
    }
  }
1048637
def next(self, *args):
        """"""
        self.initialize()
        self.future = asyncio.Future(loop=self.loop)
        self.handle = self.loop.call_at(self.get_next(), self.call_func, *args)
        return self.future
792346
private int doInvoke() {
        int s; Thread t; ForkJoinWorkerThread wt;
        if ((s = doExec()) >= 0) {
            if ((t = Thread.currentThread()) instanceof ForkJoinWorkerThread)
                s = (wt = (ForkJoinWorkerThread)t).pool.awaitJoin(wt.workQueue,
                                                                  this);
            else
                s = externalAwaitDone();
        }
        return s;
    }
219788
function nextRequest() {
		// If there are no more middleware,
		// then resolve the middleware resolution
		if ( middleware.index == middleware.names.length ) {
			middleware.resolution.resolve();
		}

		// Attempt to invoke the next middleware
		middleware.next();
	}
601034
public Object invoke(Object target, Method method, Object[] args) throws Throwable {

        PooledMethodInvocation invocation = getInvocation(target, method, args, next);

        try {
            // JIT hint
            if (next instanceof MethodInterceptorContext) {
                return next.proceed(invocation);
            }
            return next.proceed(invocation);
        } finally {
            invocation.clear();
        }
    }
1281932
function asyncIterator() {
  return {
    next: async () => {
      if (this.closed) {
        return {done: true}
      }

      try {
        return {value: await this.receive(), done: false}
      } catch (err) {
        if (this.closed && err.code == "EAGAIN") {
          return {done: true}
        } else {
          throw err
        }
      }
    },
  }
}
1187215
def _synced(method, self, args, kwargs):
    """"""
    with self._lock:
        return method(*args, **kwargs)
989078
function next() {
        $this->unmoved = false;
        if ($this->valid()) {
            $this->currentInstance++;
            if (!isset($this->instanceCache[$this->currentInstance])) {
                // try to load next block (unless we know it's empty)
                $remainingInstances = !$this->endOfResource && $this->load($this->currentInstance);
            }
        }
    }
440409
private void doProcessNext()
	{
		int _position = getPosition();
		Node _current = getSource().item(_position);

		if (getActionPool().containsKey(_current.getNodeName()))
		{
			getActionPool().get(_current.getNodeName()).execute(_current, _position);
		}
		else if (getActionPool().containsKey(NODE_NAME__DEFAULT))
		{
			getActionPool().get(NODE_NAME__DEFAULT).execute(_current, _position);
		}
		// else do nothing...

		// done
		_position++;
		setPosition(_position);
	}
457230
def fetch_synchronous(self, endpoint_name, query_params=None):
        """"""

        endpoint_url = constants.URL_PREFIX + "/" + self._version + "/" + endpoint_name

        if query_params is None:
            query_params = {}

        return self._request_client.get(endpoint_url, query_params)
57909
def invoke(self, ctx):
        
        if self.callback is not None:
            loop = asyncio.get_event_loop()
            return loop.run_until_complete(self.async_invoke(ctx))
680859
def get_next(self, query, **options):
        """"""
        iterator = EventsPageIterator(self.client, '/events', query, options)
        result = iterator.next()
        return (result, iterator.sync)
1357962
public synchronized Object get() {
        Object o = null;

        while ((o = tryGet()) == null) {
            try {
                this.wait();
            } catch (final InterruptedException e) {
            }
        }
        return o;
    }
1030508
function next() {
        if ($this->valid()) {
            $last = $this->key();
            $this->currentResult++;
            if (!isset($this->cache[$this->currentResult])) {
                $this->load($last+1);
            }
        }
    }