1 | <?php |
||
14 | trait Serve |
||
15 | { |
||
16 | /** |
||
17 | * Serve command. |
||
18 | * |
||
19 | * @param int $port |
||
|
|||
20 | */ |
||
21 | protected function serve(InputInterface $input, OutputInterface $output) |
||
39 | |||
40 | /** |
||
41 | * Check if port is in use. |
||
42 | * |
||
43 | * @param int $port |
||
44 | * @param string $host |
||
45 | * @param int $timeout |
||
46 | * |
||
47 | * @return bool |
||
48 | */ |
||
49 | protected function check_port($port = 8000, $host = '127.0.0.1', $timeout = 3) |
||
60 | |||
61 | /** |
||
62 | * Configure command. |
||
63 | */ |
||
64 | public function configure() |
||
73 | |||
74 | /** |
||
75 | * Obtain port. |
||
76 | * |
||
77 | * @param InputInterface $input |
||
78 | * @return mixed|string |
||
79 | */ |
||
80 | protected function port(InputInterface $input) { |
||
84 | |||
85 | } |
||
86 |
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.