Get all values from a list endpoint.  Used for iterators like foreach().

@return \Generator
@throws \Exception
321661
public function stream()
    {
        $endpoint = $this->getEndpoint();
        $params = $this->getParams();
        $list = $this->getClient()->request($endpoint, 'GET', $params);
        foreach ($list['items'] as $item) {
            yield $item;
        }

        while ($list['metadata']['continue']) {
            $params['continue'] = $list['metadata']['continue'];
            $list = $this->getClient()->request($endpoint, 'GET', $params);
            foreach ($list['items'] as $item) {
                yield $item;
            }
        }
    }
942231
public function getAll(): iterable
    {
        if ($this->roles === null) {
            $ids = [];
            $names = [];
            /** @var IRole[] $roles */
            $roles = array_values(entity(Role::class)->all());
            foreach ($roles as $key => $role) {
                $names[$role->name()] = $key;
                $ids[$role->id()] = $key;
            }
            $this->ids = $ids;
            $this->names = $names;
            $this->roles = $roles;
        }
        return $this->roles;
    }
1076550
public function getValues()
    {
        while ($row = $this->getNextRow()) {
            if ($this->columnCount() > 1) {
                $key = rtrim(reset($row));
                $val = rtrim(next($row));
                yield $key => $val;
            } else {
                yield rtrim(reset($row));
            }
        }
    }
252239
public function getIterator() : \Generator
    {
        for ($current = $this->start; $current->isBeforeOrEqualTo($this->end); $current = $current->plusMonths(1)) {
            yield $current;
        }
    }
393562
public function collection()
    {
        if ($this->collection) {
            return $this->collection;
        }

        if (!$this->collectionConfig()) {
            throw new Exception(sprintf(
                'Collection Config required for "%s"',
                get_class($this)
            ));
        }

        $collection = new CollectionLoader([
            'logger'  => $this->logger,
            'factory' => $this->modelFactory()
        ]);

        $collection->setModel($this->proto());
        $collection->setData($this->collectionConfig());

        $this->collection = $collection->load();

        return $this->collection;
    }
859156
public function fetch()
	{
		$this->filterByExtension();

		$results = Array();

		foreach ($this->finder as $file)
		{
			$config = new ConfigFile($this->fs, $this->fileInfo, $this->extracter);
			$config->load($file->getRealPath());
			$results[] = $config;
		}

		$this->finder = new Finder();

		return new CollectionResults($results);
	}
306505
public function getAllHostIPAddresses()
    {
        list($start_ip, $end_ip) = $this->getIPAddressRangeAsInts();

        if ($this->getNetworkSize() < 31) {
            $start_ip += 1;
            $end_ip   -= 1;
        }

        for ($ip = $start_ip; $ip <= $end_ip; $ip++) {
            yield long2ip($ip);
        }
    }
371921
public function getIterator()
    {
        $values = array();
        foreach ($this->values as $key => $val) {
            $values[$key] = array(
                'key' => $key,
                'value' => $val,
                'first' => false,
                'last' => false
            );
        }
        $keys = array_keys($values);
        if (!empty($keys)) {
            $values[reset($keys)]['first'] = true;
            $values[end($keys)]['last'] = true;
        }
        return new \ArrayIterator($values);
    }
1321848
public function values(): CollectionInterface
    {
        return $this->wrap(function (Iterator $data) {
            foreach ($data as $item) {
                yield $item;
            }
        });
    }
759037
public function getIterator()
    {
        $this->reset();

        foreach ($this->iterator as $key => $value) {
            $this->position++;
            yield $key => $value;
        }
    }
919779
public function getAll()
    {
        $endpoint = "{$this->apiUrl}/webhooks/stores";

        $res = Requests::get(
            $endpoint,
            array(),
            $this->options
        );
        $this->validateResponse($res);

        return json_decode($res->body, true);
    }
940977
private function getAllGenerators() {
        $allGenerators = array();
        foreach (fphp\Generator\Generator::getGeneratorMap() as $key => $klass)            
            $allGenerators[$key] = new $klass($this->productLine->getGeneratorSettings($key));
        return $allGenerators;
    }
1269318
public function allValues()
    {
        $raw = $this->_parameters['_raw'];
        $values = explode(',', $raw);
        $result = ArrayMethods::trim($values);
        return $result;
    }
55704
public function getIterator()
    {

        $result = $this->data !== null ? $this->data : call_user_func($this->getter);

        if (!$result) {
            return new ArrayIterator([]);
        }

        if ($result instanceof Iterator) {
            return $result;
        }

        if (is_array($result)) {
            return new ArrayIterator($result);
        }

        if (!$result instanceof Traversable) {
            throw new UnexpectedValueException('The returned result of the assigned callable is not supported (traversable)');
        }

        $array = [];

        foreach ($result as $item) {
            $array[] = $item;
        }

        return new ArrayIterator($array);
    }
1362497
public function getEndPoints()
    {
        $endPoints = array();
        if (!$this->hasChildren()) {
            return $endPoints;
        }

        foreach ($this->_children as $child) {
            $value = $child->getValue();

            if (null === $value) {
                $endPoints[] = $this;
            } elseif ((null !== $value)
                && $child->hasChildren())
            {
                $childEndPoints = $child->getEndPoints();
                if (!empty($childEndPoints)) {
                    $endPoints = array_merge($endPoints, $childEndPoints);
                }
            } elseif ((null !== $value) && !$child->hasChildren()) {
                $endPoints[] = $child;
            }
        }

        return $endPoints;
    }
201738
public function getChildren()
    {
        $driveLocator = "/drives/{$this->parentReference->driveId}";
        $itemLocator  = "/items/{$this->id}";
        $endpoint     = "$driveLocator$itemLocator/children";

        $response = $this
            ->graph
            ->createCollectionRequest('GET', $endpoint)
            ->execute();

        $status = $response->getStatus();

        if ($status != 200) {
            throw new \Exception("Unexpected status code produced by 'GET $endpoint': $status");
        }

        $driveItems = $response->getResponseAsObject(DriveItem::class);

        if (!is_array($driveItems)) {
            return [];
        }

        return array_map(function (DriveItem $driveItem) {
            return new self($this->graph, $driveItem);
        }, $driveItems);
    }
1150989
public function getResultsAsArray()
    {
        $new = array();
        foreach ((array) $this->results as $result) {
            if ($result instanceof Object)
                $new[] = $result->toArray();
            else if (is_array($result))
                return $this->results;
            else
                throw new Exception('Cannot convert to array: '.ClassUtils::getQualifiedType($result));
        }
        return $new;
    }