next() public méthode

public next ( )
Exemple #1
0
 public function next()
 {
     if ($this->_iterating === true) {
         $this->_iterating = $this->selectQuery();
         $this->_iterating->stmt = null;
         $this->_iterating->rewind();
         $this->hook('beforeLoad', array($this->_iterating));
     }
     $this->_iterating->next();
     $this->data = $this->_iterating->current();
     if ($this->data === false) {
         $this->unload();
         $this->_iterating = false;
         return;
     }
     $this->id = @$this->data[$this->id_field];
     $this->dirty = array();
     $this->hook('afterLoad');
 }