1 | <?php |
||
21 | class Broadcast |
||
22 | { |
||
23 | /** |
||
24 | * @var array |
||
25 | */ |
||
26 | protected static $channels = []; |
||
27 | /** |
||
28 | * @var RedisDriver |
||
29 | */ |
||
30 | protected $redis; |
||
31 | /** |
||
32 | * @var LoggerInterface |
||
33 | */ |
||
34 | protected $logger; |
||
35 | /** |
||
36 | * @var EventManager |
||
37 | */ |
||
38 | protected $manager; |
||
39 | /** |
||
40 | * @var Process |
||
41 | */ |
||
42 | protected $process; |
||
43 | /** |
||
44 | * @var EntityManagerInterface |
||
45 | */ |
||
46 | protected $entityManager; |
||
47 | |||
48 | /** |
||
49 | * Broadcast constructor. |
||
50 | * |
||
51 | * @param ContainerInterface $container |
||
|
|||
52 | * @param RedisDriver $redis |
||
53 | * @param EventManager $manager |
||
54 | * @param LoggerInterface $logger |
||
55 | */ |
||
56 | public function __construct(RedisDriver $redis, EventManager $manager, LoggerInterface $logger, Process $process) |
||
63 | |||
64 | /** |
||
65 | * Subscribe to event from client |
||
66 | * |
||
67 | * @param string $event |
||
68 | * @param array $data |
||
69 | * |
||
70 | * @return \Symfony\Component\Process\Process |
||
71 | * |
||
72 | * @throws Exception |
||
73 | */ |
||
74 | public function on(string $event, array $data) |
||
85 | |||
86 | /** |
||
87 | * Run process |
||
88 | * |
||
89 | * @param string $handler |
||
90 | * @param array $data |
||
91 | */ |
||
92 | public function process(string $handler, array $data) |
||
123 | |||
124 | /** |
||
125 | * Emit event to client |
||
126 | * |
||
127 | * @param string $event |
||
128 | * @param array $data |
||
129 | * |
||
130 | * @throws Exception |
||
131 | */ |
||
132 | public function emit(string $event, array $data) |
||
167 | |||
168 | /** |
||
169 | * Publish data to redis channel |
||
170 | * |
||
171 | * @param string $channel |
||
172 | * @param array $data |
||
173 | */ |
||
174 | protected function publish(string $channel, array $data) |
||
178 | |||
179 | /** |
||
180 | * Prepare channel name |
||
181 | * |
||
182 | * @param string $name |
||
183 | * |
||
184 | * @return string |
||
185 | */ |
||
186 | protected function channelName(string $name): string |
||
190 | |||
191 | /** |
||
192 | * Redis channels names |
||
193 | * |
||
194 | * @return array |
||
195 | */ |
||
196 | public function channels(): array |
||
210 | |||
211 | public function setDoctrine(EntityManagerInterface $entityManager) |
||
215 | } |
||
216 |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italy
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was removed, but the annotation was not.