Piwik\DataTable\Renderer\Csv::renderTable PHP Method

renderTable() protected method

Computes the output of the given data table
protected renderTable ( DataTable | array $table, array &$allColumns = [] ) : string
$table Piwik\DataTable | array
$allColumns array
return string
    protected function renderTable($table, &$allColumns = array())
    {
        if (is_array($table)) {
            // convert array to DataTable
            $table = DataTable::makeFromSimpleArray($table);
        }
        if ($table instanceof DataTable\Map) {
            $str = $this->renderDataTableMap($table, $allColumns);
        } else {
            $str = $this->renderDataTable($table, $allColumns);
        }
        return $str;
    }