public function rewind() { if ($this->xml) { $this->xml->close(); } $this->xml = new \XMLReader(); $this->xml->open($this->path); $this->next(); }