| 1 | <?php |
||
| 18 | final class EventIteratorCollection implements EventCollection |
||
| 19 | { |
||
| 20 | /** |
||
| 21 | * @var \Iterator |
||
| 22 | */ |
||
| 23 | private $iterator; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * EventIteratorCollection constructor. |
||
| 27 | * |
||
| 28 | * @param \Iterator $iterator |
||
| 29 | */ |
||
| 30 | public function __construct(\Iterator $iterator) |
||
| 34 | |||
| 35 | /** |
||
| 36 | * {@inheritdoc} |
||
| 37 | * |
||
| 38 | * @return Event |
||
| 39 | */ |
||
| 40 | public function current(): Event |
||
| 54 | |||
| 55 | /** |
||
| 56 | * {@inheritdoc} |
||
| 57 | */ |
||
| 58 | public function next(): void |
||
| 62 | |||
| 63 | /** |
||
| 64 | * {@inheritdoc} |
||
| 65 | * |
||
| 66 | * @return string|int|null |
||
|
|
|||
| 67 | */ |
||
| 68 | public function key() |
||
| 72 | |||
| 73 | /** |
||
| 74 | * {@inheritdoc} |
||
| 75 | */ |
||
| 76 | public function valid(): bool |
||
| 80 | |||
| 81 | /** |
||
| 82 | * {@inheritdoc} |
||
| 83 | */ |
||
| 84 | public function rewind(): void |
||
| 88 | } |
||
| 89 |
This check compares the return type specified in the
@returnannotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.