source/Spiral/ORM/Entities/RecordSelector.php
public function fetchAll(
        string $cacheKey = '',
        $ttl = 0,
        CacheInterface $cache = null
    ): array {
        return iterator_to_array($this->getIterator($cacheKey, $ttl, $cache));
    }
public function fetchAll(
        string $cacheKey = '',
        $ttl = 0,
        CacheInterface $cache = null
    ): array {
        return iterator_to_array($this->getIterator($cacheKey, $ttl, $cache));
    }
public function fetchAll ( string $ cacheKey = '' , $ ttl = 0 , CacheInterface $ cache = null ) : array { return iterator_to_array ( $ this -> getIterator ( $ cacheKey , $ ttl , $ cache ) ) ; }
Fetch all records in a form of array.

@param string              $cacheKey
@param int|\DateInterval   $ttl
@param CacheInterface|null $cache Can be automatically resoled via ORM container scope.

@return RecordInterface[]
Fetch all records in a form of array .