public function next_row($type = 'object') { $result = $this->result($type); if (count($result) === 0) { return NULL; } return isset($result[$this->current_row + 1]) ? $result[++$this->current_row] : NULL; }