1 | <?php |
||
13 | class Attribute |
||
14 | { |
||
15 | /** |
||
16 | * @var Attribute |
||
17 | */ |
||
18 | protected $property; |
||
19 | |||
20 | /** |
||
21 | * PropertyFactory constructor. |
||
22 | * @param Property $property |
||
23 | */ |
||
24 | public function __construct(Property $property) |
||
28 | |||
29 | public function required(): self |
||
35 | |||
36 | public function optional(): self |
||
42 | |||
43 | public function rule($rules): self |
||
49 | |||
50 | public function nullable(): self |
||
56 | |||
57 | public function default($value): self |
||
63 | |||
64 | public function constraint(Closure $callback): self |
||
70 | |||
71 | public function getProperty(): Property |
||
75 | } |
||
76 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..