We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
1 | <?php |
||
26 | final class Factory |
||
27 | { |
||
28 | /** |
||
29 | * @var string[] |
||
30 | */ |
||
31 | private $namespaces; |
||
32 | |||
33 | /** |
||
34 | * @var self |
||
35 | */ |
||
36 | private static $defaultInstance; |
||
37 | |||
38 | /** |
||
39 | * Initializes the rule with the defined namespaces. |
||
40 | * |
||
41 | * If the default namespace is not in the array, it will be add to the end |
||
42 | * of the array. |
||
43 | * |
||
44 | * @param array $namespaces |
||
45 | */ |
||
46 | 11 | public function __construct(array $namespaces = []) |
|
54 | |||
55 | /** |
||
56 | * Returns a list of namespaces. |
||
57 | * |
||
58 | * @return array |
||
59 | */ |
||
60 | 9 | public function getNamespaces(): array |
|
64 | |||
65 | /** |
||
66 | * Creates a rule based on its name with the defined arguments. |
||
67 | * |
||
68 | * @param string $ruleName |
||
69 | * @param array $arguments |
||
70 | * |
||
71 | * @throws ComponentException When the rule cannot be created |
||
72 | * |
||
73 | * @return Rule |
||
74 | */ |
||
75 | 6 | public function rule(string $ruleName, array $arguments = []): Rule |
|
97 | |||
98 | /** |
||
99 | * Defines the default instance of the factory. |
||
100 | * |
||
101 | * @param Factory $factory |
||
102 | */ |
||
103 | 1 | public static function setDefaultInstance(self $factory) |
|
107 | |||
108 | /** |
||
109 | * Returns the default instance of the factory. |
||
110 | * |
||
111 | * @return self |
||
112 | */ |
||
113 | 2 | public static function getDefaultInstance(): self |
|
121 | } |
||
122 |
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..