Iterates over this readahead iterator

@return boolean true if there is a next item.
555649
public function iterate()
    {
        $this->current = $this->getNext();
        $this->key = $this->getNextKey();

        $valid = $this->current !== null;

        if ($valid) {
            $this->iterator->next();
        }

        return $valid;
    }
832118
public function hasNextSibling(): bool
    {
        try
        {
            $this->nextSibling();

            // sibling found, return true;
            return true;
        }
        catch (ParentNotFoundException $e)
        {
            // no parent, no next sibling
            return false;
        }
        catch (ChildNotFoundException $e)
        {
            // no sibling found
            return false;
        }
    }
527852
public function dir_readdir() {
    // Current file list will be null if there was a rewind.
    if (is_null($this->current_file_list)) {
      if (!$this->fillFileBuffer()) {
        return false;
      }
    } else if (empty($this->current_file_list)) {
      // If there is no next marker, or we cannot fill the buffer, we are done.
      if (!isset($this->next_marker) || !$this->fillFileBuffer()) {
        return false;
      }
    }

    // The file list might be empty if out next_marker was actually the last
    // file in the list.
    if (empty($this->current_file_list)) {
      return false;
    } else {
      return array_shift($this->current_file_list);
    }
  }
295760
protected function NextItem()
	{
		MoveNextIter:
		if ( ! $this->accept)
		{
			if ( ! $this->MoveNextIter() )
			{
				return null;
			}
			if ( $this->matchSelf && $this->TestItem() )
			{
				$this->sequentialPosition++;
				return $this->curr;
			}
		}

		MoveToFirstChild:
		if ( $this->curr->MoveToFirstChild() )
		{
			$this->depth++;
			goto TestItem;
		}

		MoveToNext:
		if ( $this->depth == 0 )
		{
			$this->accept = false;
			goto MoveNextIter;
		}
		if ( ! $this->curr->MoveToNext() )
		{
			$this->curr->MoveToParent();
			$this->depth--;
			goto MoveToNext;
		}

		TestItem:
		if ( ! $this->TestItem() )
		{
			goto MoveToFirstChild;
		}
		$this->sequentialPosition++;
		return $this->curr;
	}
650638
public function dir_readdir()
    {
        $dir = $this->dirIterator->current();
        if (null === $dir) {
            return false;
        }

        $this->dirIterator->next();
        return $dir->getName();
    }
1205755
public function hasReadAccess() : bool
   {

      return $this->isOpen()
         && (
               $this->access == static::ACCESS_READ
            || $this->access == static::ACCESS_READWRITE
         );

   }
1259811
public function next()
    {
        $this->firstItemIdx++;

        if (isset($this->firstItems[$this->firstItemIdx])) {
            return $this->firstItems[$this->firstItemIdx][1];
        } else {
            if (!isset($this->firstItems[$this->firstItemIdx - 1])) {
                $this->items->next();
            }

            if ($this->excludedItems) {
                while (($c = $this->items->current()) && in_array($c->{$this->keyField}, $this->excludedItems, true)) {
                    $this->items->next();
                }
            }
        }

        if (!$this->items->valid()) {
            // iterator has passed the preface items, off the end of the items
            // list. Track through the end items to go through to the next
            if ($this->endItemIdx === null) {
                $this->endItemIdx = -1;
            }

            $this->endItemIdx++;

            if (isset($this->lastItems[$this->endItemIdx])) {
                return $this->lastItems[$this->endItemIdx];
            }

            return false;
        }
    }
1309208
public boolean hasNext()
  {
    boolean hasNext = false;

    if(_currentSubIterator == null || !_currentSubIterator.hasNext())
    {
      nextQueue();
    }

    if(_currentSubIterator != null)
    {
      hasNext = _currentSubIterator.hasNext(); 
    }
    
    return hasNext;
  }
608960
public function next() {
		if ($this->currentRecord < count($this->files)) {
			$file = $this->files[$this->currentRecord];
			$this->currentRecord++;
			return $file;
		} else {
			return false;
		}
	}
712084
public function next()
    {
        $value = $this->_skipNext ? current($this->_data) : next($this->_data);
        $this->_skipNext = false;
        return key($this->_data) !== null ? $value : null;
    }
235596
public function next(){

		if(next($this->_fetched) instanceof SQLResultRow){

			return current($this->_fetched);
		}
		else{

			try{

				$mySQLResultRow = new MySQLResultRow($this->_result);
			}
			catch(SQLResultRowException $e){

				return false;
			}

			// Clear fetch buffer in case of an unbuffered result-set

			if(!$this->_buffered){

				$this->_fetched = [];
			}

			$this->_fetched[] = $mySQLResultRow;

			return $mySQLResultRow;
		}
	}
1255771
protected function NextItem()
	{
		while (true)
		{
			if ( ! $this->accept)
			{
				if ( ! $this->MoveNextIter() )
					return null;
				$this->nav = $this->curr->CloneInstance();
				$this->curr->MoveToRoot();
			}
			$this->accept = $this->curr->MoveToFollowing( $this->kind, $this->nav );
			if ( $this->accept )
			{
				if ( $this->curr->isNodeAncestorOf( $this->nav ) ) continue;

				if ( $this->TestItem() )
				{
					$this->sequentialPosition++;
					return $this->curr;
				}
			}
		}
	}
1194781
public function next()
    {
        $keys  = array_keys($this->items);
        $index = array_search($this->currentKey, $keys);

        $index++;

        $this->currentKey = array_key_exists($index, $keys) ? $keys[$index] : null;
    }
254288
public function read() {
		$buff = @fread($this->socket, 1024);
		if(!$buff) {
			if($this->reconnect) {
				$this->doReconnect();
			} else {
				fclose($this->socket);
				return false;
			}
		}
		$this->log->log("RECV: $buff",  Net_XMPP_XMPPHP_Log::LEVEL_VERBOSE);
		xml_parse($this->parser, $buff, false);
	}
655188
final public function current()
    {
        if ($this->position === -1) {
            $this->next();
        }

        Util::ensure(
            true,
            array_key_exists($this->position, $this->results),
            '\OutOfBoundsException',
            ['Collection contains no element at current position']
        );

        return call_user_func_array($this->loader, [$this->results[$this->position]]);
    }
372456
public function next()
    {
        $this->_itemValid = true;

        if (!prev($this->_items)) {
            // no next item
            $this->_itemValid = false;
        } else {
            $this->_itemPosition--;
        }
    }
1259068
public function next()
    {
        // Try to get an object
        $this->current = $current = $this->reader->fetchObject($this->class);

        if ($current) {
            $this->key++;
        }
    }