Box\Spout\Reader\ODS\RowIterator::rewind PHP Method

rewind() public method

NOTE: It can only be done once, as it is not possible to read an XML file backwards.
public rewind ( ) : void
return void
    public function rewind()
    {
        // Because sheet and row data is located in the file, we can't rewind both the
        // sheet iterator and the row iterator, as XML file cannot be read backwards.
        // Therefore, rewinding the row iterator has been disabled.
        if ($this->hasAlreadyBeenRewound) {
            throw new IteratorNotRewindableException();
        }
        $this->hasAlreadyBeenRewound = true;
        $this->lastRowIndexProcessed = 0;
        $this->nextRowIndexToBeProcessed = 1;
        $this->rowDataBuffer = null;
        $this->hasReachedEndOfFile = false;
        $this->next();
    }