2021-05-10 00:23:30 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
/*
|
|
|
|
* This file is part of the Symfony package.
|
|
|
|
*
|
|
|
|
* (c) Fabien Potencier <fabien@symfony.com>
|
|
|
|
*
|
|
|
|
* For the full copyright and license information, please view the LICENSE
|
|
|
|
* file that was distributed with this source code.
|
|
|
|
*/
|
2022-02-15 12:37:44 +00:00
|
|
|
namespace RectorPrefix20220215\Symfony\Component\Console\Helper;
|
2021-05-10 00:23:30 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @internal
|
|
|
|
*/
|
|
|
|
class TableRows implements \IteratorAggregate
|
|
|
|
{
|
2021-12-09 13:05:29 +00:00
|
|
|
/**
|
|
|
|
* @var \Closure
|
|
|
|
*/
|
2021-05-10 00:23:30 +00:00
|
|
|
private $generator;
|
2021-11-30 07:57:42 +00:00
|
|
|
public function __construct(\Closure $generator)
|
2021-05-10 00:23:30 +00:00
|
|
|
{
|
|
|
|
$this->generator = $generator;
|
|
|
|
}
|
|
|
|
public function getIterator() : \Traversable
|
|
|
|
{
|
2021-11-30 07:57:42 +00:00
|
|
|
return ($this->generator)();
|
2021-05-10 00:23:30 +00:00
|
|
|
}
|
|
|
|
}
|