| 1 | <?php |
||
| 12 | class JsonApiIteratorView extends AbstractJsonApiView implements \IteratorAggregate |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * Iterator supposed to provide data for handling |
||
| 16 | * |
||
| 17 | * @var \Traversable |
||
| 18 | */ |
||
| 19 | protected $iterator; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * JsonApiIteratorView constructor. |
||
| 23 | * |
||
| 24 | * @param \Traversable $iterator |
||
| 25 | * @param int $status |
||
| 26 | * @param array $headers |
||
| 27 | */ |
||
| 28 | 3 | public function __construct(\Traversable $iterator, int $status = 200, array $headers = []) |
|
| 34 | |||
| 35 | /** |
||
| 36 | * {@inheritdoc} |
||
| 37 | */ |
||
| 38 | 1 | public function getIterator() |
|
| 42 | } |