| Total Complexity | 8 |
| Total Lines | 45 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 8 | class FlattenIterator implements IteratorAggregate |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * @var iterable<iterable> |
||
| 12 | */ |
||
| 13 | private iterable $iterables; |
||
| 14 | |||
| 15 | private bool $preserveKeys; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * @param iterable<iterable> $iterables |
||
| 19 | */ |
||
| 20 | public function __construct(iterable $iterables, bool $preserveKeys = false) |
||
| 24 | } |
||
| 25 | |||
| 26 | /** |
||
| 27 | * @inheritDoc |
||
| 28 | */ |
||
| 29 | public function getIterator(): Traversable |
||
| 42 | } |
||
| 43 | } |
||
| 44 | } |
||
| 45 | } |
||
| 46 | |||
| 47 | /** |
||
| 48 | * @return array|FlattenIterator |
||
| 49 | */ |
||
| 50 | public function asArray(): array |
||
| 55 |