function Table::getRowColumns
Gets list of columns for the given row.
1 call to Table::getRowColumns()
- Table::renderRow in vendor/
symfony/ console/ Helper/ Table.php - Renders table row.
File
-
vendor/
symfony/ console/ Helper/ Table.php, line 790
Class
- Table
- Provides helpers to display a table.
Namespace
Symfony\Component\Console\HelperCode
private function getRowColumns(array $row) : array {
$columns = range(0, $this->numberOfColumns - 1);
foreach ($row as $cellKey => $cell) {
if ($cell instanceof TableCell && $cell->getColspan() > 1) {
// exclude grouped columns.
$columns = array_diff($columns, range($cellKey + 1, $cellKey + $cell->getColspan() - 1));
}
}
return $columns;
}