| Total Complexity | 4 |
| Total Lines | 33 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 8 | class GameCollection implements \IteratorAggregate |
||
| 9 | { |
||
| 10 | private array $games = []; |
||
| 11 | |||
| 12 | public static function createFromArrayResponse(array $response): self |
||
| 21 | } |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @return ArrayIterator|\Traversable|Game[] |
||
| 25 | */ |
||
| 26 | public function getIterator(): ArrayIterator |
||
| 27 | { |
||
| 28 | return new ArrayIterator($this->games); |
||
| 29 | } |
||
| 30 | |||
| 31 | /** |
||
| 32 | * @return Game[] |
||
| 33 | */ |
||
| 34 | public function sortedByDate(): array |
||
| 41 | } |
||
| 42 | } |
||
| 43 |