various improvements

This commit is contained in:
Adrien Loison committed 2017-11-19 02:41:07 +01:00
1 parent 102e17159c
commit 4d1d1c1e87
19 files changed
+90 -112

No files matched your search

@@ -65,6 +65,24 @@ class InternalEntityFactory implements InternalEntityFactoryInterface
return new RowIterator($filePointer, $optionsManager, $encodingHelper, $this, $globalFunctionsHelper);
}
/**
* @param Cell[] $cells
* @return Row
*/
public function createRow(array $cells = [])
{
return new Row($cells);
}
/**
* @param mixed $cellValue
* @return Cell
*/
public function createCell($cellValue)
{
return new Cell($cellValue);
}
/**
* @param array $cellValues
* @return Row
@@ -72,9 +90,9 @@ class InternalEntityFactory implements InternalEntityFactoryInterface
public function createRowFromArray(array $cellValues = [])
{
$cells = array_map(function ($cellValue) {
return new Cell($cellValue);
return $this->createCell($cellValue);
}, $cellValues);
return new Row($cells);
return $this->createRow($cells);
}
}