| 1 | <?php |
||
| 10 | class Processor implements ProcessorInterface |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * @var DriverFactory |
||
| 14 | */ |
||
| 15 | private $driverFactory; |
||
| 16 | |||
| 17 | public function __construct(DriverFactory $driverFactory) |
||
| 21 | |||
| 22 | /** |
||
| 23 | * @param TaskTypeInterface $task |
||
| 24 | * @return TaskResult |
||
| 25 | */ |
||
| 26 | public function process(TaskTypeInterface $task) |
||
| 62 | } |
||
| 63 |
If a method or function can return multiple different values and unless you are sure that you only can receive a single value in this context, we recommend to add an additional type check:
If this a common case that PHP Analyzer should handle natively, please let us know by opening an issue.