1 | <?php |
||
17 | class Environment implements WatcherInterface |
||
18 | { |
||
19 | /** |
||
20 | * Environment variable. |
||
21 | * |
||
22 | * @var array |
||
23 | */ |
||
24 | protected $vars; |
||
25 | |||
26 | /** |
||
27 | * Environment constructor. |
||
28 | * |
||
29 | * @param array|string $vars |
||
30 | * @param mixed $value |
||
31 | */ |
||
32 | public function __construct($vars, $value = null) |
||
44 | |||
45 | /** |
||
46 | * Set environment variable. |
||
47 | * |
||
48 | * @param string $var |
||
49 | * @param mixed $value |
||
50 | * |
||
51 | * @return $this |
||
52 | */ |
||
53 | public function addVariable($var, $value = null) |
||
61 | |||
62 | /** |
||
63 | * {@inheritdoc} |
||
64 | */ |
||
65 | public function isActive() |
||
81 | |||
82 | /** |
||
83 | * Test for environment variable. |
||
84 | * |
||
85 | * @param string $var |
||
|
|||
86 | * |
||
87 | * @return bool |
||
88 | */ |
||
89 | protected function isEnvVariableDefined($variable) |
||
93 | |||
94 | /** |
||
95 | * Get environment variable value. |
||
96 | * |
||
97 | * @param string $variable |
||
98 | * |
||
99 | * @return mixed |
||
100 | */ |
||
101 | protected function getEnvVariableValue($variable) |
||
123 | } |
||
124 |
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.