Actually fetch all the items with the given params

@param $page
@param $pagination
@param $where
@return \stdClass[]
764244
public function fetchAll($page, $pagination, $where)
    {
        $index = ceil(($page - 1) * $pagination);

        $where = $this->formatWhereClause($where);

        $sql = "
			select " . $this->getMappingAsSQL() . "
			from " . $this->getTable() . "
			" . $where . "
			limit " . $index . ',' . intval($pagination) . ";";

        $query = $this->driver->query($sql, [], static::DATA_OBJECT_CLASS);

        return $query->result();
    }
42166
public function fetchAll($paginated = false)
    {
        if ($paginated) {
            $paginatorAdapter   = new DbTableGateway($this->tableGateway);
            $paginator          = new Paginator($paginatorAdapter);

            return $paginator;
        }

        $resultSet = $this->getTableGateway()->select();

        return $resultSet;
    }
23749
public function getPaginator( $where = null, $order = null )
    {
        return $this->getMapper()
                    ->getPaginator( $where, $order );
    }
400179
public function paginate($fetchMode = PDO::FETCH_ASSOC) {
        $this->fields = $this->fields?$this->fields:'*';
        $this->fields = 'SQL_CALC_FOUND_ROWS '.$this->fields;
        $result = $this->query()->fetchAll($fetchMode);
        $result = $this->_data($result,true);
        $num = $this->sql('SELECT FOUND_ROWS()')->fetchColumn();
        return [$num,$result];
    }
140992
public function getPaginator( $where        = null,
                                  $order        = null,
                                  $columns      = null,
                                  $joins        = null,
                                  $quantifier   = null )
    {
        $joins = array_merge( (array) $joins, array(
            'rootParagraph' => array(
                'table'     => array(
                    'rootParagraph' => $this->getTableInSchema( 'paragraph' )
                ),
                'where'     => 'customize_rule.rootParagraphId = rootParagraph.id',
                'type'      => Sql\Select::JOIN_LEFT,
                'columns'   => array(
                    'rootType'  => 'type',
                    'rootName'  => 'name',
                ),
            ),
        ) );

        return parent::getPaginator( $where, $order, $columns, $joins, $quantifier );
    }
473412
protected function getPaginationData(Select $query, array $options)
    {
        // Get pagination options
        $page = (int) Arr::get($options, 'page');

        if ($page < 1) {
            $page = 1;
        }

        $resultsPerPage = Arr::get(
            $options,
            'resultsPerPage',
            $this->resultsPerPage
        );

        // Get total results
        $resultCount = $this->getQueryResultCount($query);
        $pageCount   = ceil($resultCount / $resultsPerPage);

        return new PaginationData([
            'page'             => $page,
            'page_count'       => $pageCount,
            'result_count'     => $resultCount,
            'results_per_page' => $resultsPerPage
        ]);
    }
137700
public function getPagedResults($limit = 25, $page = 0)
    {
        $template = self::DQL_ALL;
        $dql = sprintf($template, Application::class);

        return $this->getPaginator($dql, $limit, $page, []);
    }
1126290
static public function paginate($page, $per_page)
    {
        $query = self::createRelation();
        return $query->paginate($page, $per_page);
    }
1331291
public function find($where = null, $orderby = null, $onpage = null, $page = null)
  {
    $this->items = null;

    $q = $this->getManager()
      ->getQueryBuilder()
      ->select($this->getTable())
      ->where($where)
      ->orderby($orderby)
      ->page($page, $onpage);

    return $this->fetch($q);
  }
269403
public function findAllPaged($page = 0, $limit = 20) {
    $results = $this->findAllWithoutFetchPaged($page, $limit);
    $return = $this->hydrate($results);

    return $return;
  }
708810
private function getQueryOptions($pagination)
    {
        // Some options that are the same for all three cases
        $options = [
            'order'     => 'date',
            'direction' => 'DESC',
        ];

        if ($pagination['limit']) {
            $options['limit'] = $pagination['limit'];
        }
        if ($pagination['page'] > 0 && $pagination['limit']) {
            $options['offset'] = ($pagination['page'] - 1) * $pagination['limit'];
        }

        return $options;
    }
1299414
public function pagination($page, $limit, $query = null, $orderBy = null, $sort = 'ASC', $filter = null)
    {
        return $this->getMapper()->pagination($page, $limit, $query, $orderBy, $sort, $filter);
    }
861182
public function findPageBy($page, $rpp, array $criteria = [], array $orderBy = null, $hydrateMode = AbstractQuery::HYDRATE_OBJECT)
    {
        $qb = $this->createPaginatedQueryBuilder($criteria, null, $orderBy);
        $qb->addSelect($this->getEntityAlias());
        $this->processOrderBy($qb, $orderBy);
        $qb->addPagination($page, $rpp);

        $results = $qb->getQuery()->getResult($hydrateMode);
        $total = $this->countBy($criteria);

        return new PaginatedArrayCollection($results, $page, $rpp, $total);
    }
1120213
public function fetchResults($query, $page = 1, $maxPerPage = 10, $filter = false, $paginate = false)
    {
        if ($paginate) {
            if (!$this->pager) {
                throw new \Exception('Please inject a pager on ResultBuilder');
            }

            $results = $this->pager->paginate($query, $page, $maxPerPage);
        } else {
            $results = $this->queryExecutor->fetch($query, $page, $maxPerPage);
        }

        if ($filter) {
            return $this->filterManager->filter($results);
        }

        return $results;
    }
1128555
public function getByTarget(Target $target, $limit = 50, $page = 0)
    {
        $dql = sprintf(self::DQL_BY_TARGET, Release::class);
        $params = ['target' => $target];

        return $this->getPaginator($dql, $limit, $page, $params);
    }
902404
public function getPagedResults($limit = 50, $page = 0): Paginator
    {
        $dql = sprintf(self::DQL_GET_PAGED, TargetTemplate::class);
        return $this->getPaginator($dql, $limit, $page);
    }
1327499
public function findAllPaginated($offset = null, $limit = null)
    {
        $qb = $this
            ->createQueryBuilder('w')
            ->orderBy('w.id')
            ->setMaxResults($limit);
        if ($offset) {
            $qb->setFirstResult($offset);
        }

        return $qb->getQuery()->getResult();
    }