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

Breadcrumb

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

function Table::calculateNumberOfColumns

Calculate number of columns for this table.

1 call to Table::calculateNumberOfColumns()
Table::render in vendor/symfony/console/Helper/Table.php
Renders table to output.

File

vendor/symfony/console/Helper/Table.php, line 603

Class

Table
Provides helpers to display a table.

Namespace

Symfony\Component\Console\Helper

Code

private function calculateNumberOfColumns(array $rows) : void {
    $columns = [
        0,
    ];
    foreach ($rows as $row) {
        if ($row instanceof TableSeparator) {
            continue;
        }
        $columns[] = $this->getNumberOfColumns($row);
    }
    $this->numberOfColumns = max($columns);
}

API Navigation

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