1 | <?php |
||
19 | class Process |
||
20 | { |
||
21 | /** |
||
22 | * @var array |
||
23 | */ |
||
24 | private static $_inWork = []; |
||
25 | |||
26 | /** |
||
27 | * @var |
||
28 | */ |
||
29 | public $yiiAlias; |
||
30 | |||
31 | /** |
||
32 | * @return int |
||
33 | */ |
||
34 | public function getParallelEnv(): int |
||
38 | |||
39 | /** |
||
40 | * Run process. If more then limit then wait and try run process on more time. |
||
41 | * |
||
42 | * @param string $handle |
||
43 | * @param array $data |
||
44 | * |
||
45 | * @return \Symfony\Component\Process\Process |
||
46 | */ |
||
47 | public function run(string $handle, array $data) |
||
59 | |||
60 | /** |
||
61 | * In work processes |
||
62 | */ |
||
63 | private function inWork() |
||
71 | |||
72 | /** |
||
73 | * Create cmd process and push to queue. |
||
74 | * |
||
75 | * @param string $handle |
||
76 | * @param array $data |
||
77 | * |
||
78 | * @return \Symfony\Component\Process\Process |
||
79 | */ |
||
80 | private function push(string $handle, array $data): \Symfony\Component\Process\Process |
||
100 | } |
||
101 |
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.