Box\Spout\Writer\AbstractWriter::addRows PHP Method

addRows() public method

Write given data to the output. New data will be appended to end of stream.
public addRows ( array $dataRows ) : AbstractWriter
$dataRows array Array of array containing data to be streamed. If a row is empty, it won't be added (i.e. not even as a blank row) Example: $dataRows = [ ['data11', 12, , '', 'data13'], ['data21', 'data22', null, false], ];
return AbstractWriter
    public function addRows(array $dataRows)
    {
        if (!empty($dataRows)) {
            $firstRow = reset($dataRows);
            if (!is_array($firstRow)) {
                throw new InvalidArgumentException('The input should be an array of arrays');
            }
            foreach ($dataRows as $dataRow) {
                $this->addRow($dataRow);
            }
        }
        return $this;
    }