1 | <?php |
||
20 | class Data extends Model |
||
21 | { |
||
22 | /** |
||
23 | * Parse a yaml file. |
||
24 | * |
||
25 | * @param string $yaml |
||
26 | * @param string $overrideYaml |
||
|
|||
27 | * |
||
28 | * @return array |
||
29 | */ |
||
30 | 9 | public static function fromYaml($yaml): array |
|
34 | |||
35 | /** |
||
36 | * Replace placeholders with enviroment variables. |
||
37 | * |
||
38 | * Placeholders start with % and end with %. This will be replaced by the |
||
39 | * environment variable with the name SCHEMATIC_{PLACEHOLDER}. If the |
||
40 | * environment variable is not set an exception will be thrown. |
||
41 | * |
||
42 | * @param string $yaml |
||
43 | * |
||
44 | * @return string |
||
45 | * |
||
46 | * @throws Exception |
||
47 | */ |
||
48 | public static function replaceEnvVariables($yaml): string |
||
70 | |||
71 | /** |
||
72 | * Convert array to yaml. |
||
73 | * |
||
74 | * @param array $data |
||
75 | * |
||
76 | * @return string |
||
77 | */ |
||
78 | 3 | public static function toYaml(array $data): string |
|
82 | |||
83 | /** |
||
84 | * Read yaml file and parse content. |
||
85 | * |
||
86 | * @param $file |
||
87 | * @return array |
||
88 | * @throws Exception |
||
89 | */ |
||
90 | public static function parseYamlFile($file): array |
||
102 | } |
||
103 |
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.