| 1 | <?php |
||
| 26 | abstract class AbstractParser |
||
| 27 | { |
||
| 28 | /** |
||
| 29 | * The .env to parse |
||
| 30 | * |
||
| 31 | * @var string $file |
||
| 32 | */ |
||
| 33 | protected $file; |
||
| 34 | |||
| 35 | /** |
||
| 36 | * If to throw ParseException in the .env |
||
| 37 | * |
||
| 38 | * @var bool $origin_exception |
||
| 39 | */ |
||
| 40 | protected $origin_exception; |
||
| 41 | |||
| 42 | /** |
||
| 43 | * The abstract parser constructor for Env |
||
| 44 | * |
||
| 45 | * @param string $file The file to use with Env |
||
| 46 | * @param bool $origin_exception If to throw exceptions in the origin file |
||
| 47 | */ |
||
| 48 | 45 | public function __construct($file, $origin_exception) |
|
| 53 | |||
| 54 | /** |
||
| 55 | * Returns if value starts with a value |
||
| 56 | * |
||
| 57 | * @param string $value The value to search for |
||
|
|
|||
| 58 | * @param string $line The line to test |
||
| 59 | * |
||
| 60 | * @return bool Returns if the line starts with value |
||
| 61 | */ |
||
| 62 | 42 | protected function startsWith($string, $line) |
|
| 66 | } |
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
$italyis not defined by the methodfinale(...).The most likely cause is that the parameter was removed, but the annotation was not.