Akeneo\Component\SpreadsheetParser\Xlsx\RowIteratorFactory::create PHP Method

create() public method

Creates a row iterator for the XML given worksheet file
public create ( ValueTransformer $valueTransformer, string $path, array $options, Akeneo\Component\SpreadsheetParser\Xlsx\Archive $archive ) : RowIterator
$valueTransformer ValueTransformer the value transformer for the spreadsheet
$path string the path to the extracted XML worksheet file
$options array options specific to the format
$archive Akeneo\Component\SpreadsheetParser\Xlsx\Archive The Archive from which the path was extracted
return RowIterator
    public function create(ValueTransformer $valueTransformer, $path, array $options, Archive $archive)
    {
        return new $this->iteratorClass($this->rowBuilderFactory, $this->columnIndexTransformer, $valueTransformer, $path, $options, $archive);
    }

Usage Example

 public function it_creates_row_iterators(ValueTransformer $valueTransformer, RowIteratorFactory $rowIteratorFactory, RowIterator $rowIterator1, RowIterator $rowIterator2)
 {
     $rowIteratorFactory->create($valueTransformer, 'temp_path1', [])->willReturn($rowIterator1);
     $rowIteratorFactory->create($valueTransformer, 'temp_path2', [])->willReturn($rowIterator2);
     $this->createRowIterator(0)->shouldReturn($rowIterator1);
     $this->createRowIterator(1)->shouldReturn($rowIterator2);
 }
All Usage Examples Of Akeneo\Component\SpreadsheetParser\Xlsx\RowIteratorFactory::create
RowIteratorFactory