protected function applyPaging() { $paginator = $this->getPaginator()->setItemCount($this->getCount())->setPage($this->page); $perPage = $this->getPerPage(); if ($perPage !== NULL && !in_array($perPage, $this->perPageList)) { trigger_error("The number '{$perPage}' of items per page is out of range.", E_USER_NOTICE); $perPage = $this->defaultPerPage; } $this->model->limit($paginator->getOffset(), $paginator->getLength()); }
public function limit($offset, $limit) { $this->dataSource->limit($offset, $limit); }