public function next() { do { $this->_key = next($this->_keys); } while (!isset($_SESSION[$this->_key]) && $this->_key !== false); }