/** * This returns the next chunk of database result objects. * * @return array|null Set of Omeka_Record instances, or null if none can be * found. * @author Eric Rochester <*****@*****.**> **/ public function next() { $this->pageNumber++; $this->select->limitPage($this->pageNumber, $this->rowCount); $rows = $this->table->fetchObjects($this->select, $this->params); return $rows; }
/** * Render sql select limit * * @return Varien_Data_Collection_Db */ protected function _renderLimit() { if ($this->_pageSize) { $this->_select->limitPage($this->getCurPage(), $this->_pageSize); } return $this; }
/** * Apply pagination to a select object via the LIMIT and OFFSET clauses. * * @param Zend_Db_Select $select * @param integer $limit Number of results per "page". * @param integer|null $page Page to retrieve, first if omitted. * @return Zend_Db_Select */ public function applyPagination($select, $limit, $page = null) { if ($page) { $select->limitPage($page, $limit); } else { $select->limit($limit); } return $select; }
/** * @return WeFlex_Db_Model */ public function limitPage($page, $rowCount) { $this->_selector->limitPage($page, $rowCount); return $this; }