| 1 | <?php |
||
| 9 | class AfterCollectingFieldRules |
||
| 10 | { |
||
| 11 | /** |
||
| 12 | * The field instance. |
||
| 13 | * |
||
| 14 | * @var FormField |
||
| 15 | */ |
||
| 16 | protected $field; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * The field's rules. |
||
| 20 | * |
||
| 21 | * @var Rules |
||
| 22 | */ |
||
| 23 | protected $rules; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * Create a new after field creation instance. |
||
| 27 | * |
||
| 28 | * @param Form $form |
||
|
|
|||
| 29 | * @param FormField $field |
||
| 30 | * @return void |
||
| 31 | */ |
||
| 32 | 9 | public function __construct(FormField $field, Rules $rules) { |
|
| 36 | |||
| 37 | /** |
||
| 38 | * Return the event's field. |
||
| 39 | * |
||
| 40 | * @return FormField |
||
| 41 | */ |
||
| 42 | public function getField() { |
||
| 45 | |||
| 46 | /** |
||
| 47 | * Return the event's field's rules. |
||
| 48 | * |
||
| 49 | * @return Rules |
||
| 50 | */ |
||
| 51 | public function getRules() { |
||
| 54 | } |
||
| 55 |
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.