PhpBench\Report\Renderer\ConsoleRenderer::render PHP Method

render() public method

Render the table.
public render ( PhpBench\Dom\Document $reportDom, Config $config )
$reportDom PhpBench\Dom\Document
$config PhpBench\Registry\Config
    public function render(Document $reportDom, Config $config)
    {
        foreach ($reportDom->firstChild->query('./report') as $reportEl) {
            $title = $reportEl->getAttribute('title');
            if ($title) {
                $this->output->writeln(sprintf('<title>%s</title>', $title));
                $this->output->writeln(sprintf('<title>%s</title>', str_repeat('=', strlen($title))));
                $this->output->write(PHP_EOL);
            }
            foreach ($reportEl->query('./description') as $descriptionEl) {
                $this->output->writeln(sprintf('<description>%s</description>', $descriptionEl->nodeValue));
                $this->output->writeln('');
            }
            foreach ($reportEl->query('.//table') as $tableEl) {
                $this->output->writeln(sprintf('<subtitle>%s</subtitle>', $tableEl->getAttribute('title')));
                $this->renderTableElement($tableEl, $config);
            }
        }
    }