| Conditions | 3 |
| Paths | 3 |
| Total Lines | 14 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 9 | public function __construct(array $transformers) |
||
| 10 | { |
||
| 11 | foreach ($transformers as $transformer) { |
||
| 12 | if ($transformer instanceof TransformerInterface) { |
||
| 13 | continue; |
||
| 14 | } |
||
| 15 | |||
| 16 | throw new \InvalidArgumentException( |
||
| 17 | 'All transformers in the chain should implement TransformerInterface.' |
||
| 18 | ); |
||
| 19 | } |
||
| 20 | |||
| 21 | $this->transformers = $transformers; |
||
| 22 | } |
||
| 23 | |||
| 33 |