Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Table.php

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\Helper

Code

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;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal