1 | <?php |
||
19 | abstract class AbstractForm extends Fieldset implements FormInterface |
||
20 | { |
||
21 | /** |
||
22 | * @var SubjectFilter |
||
23 | */ |
||
24 | protected $filter; |
||
25 | |||
26 | /** |
||
27 | * @var null | array |
||
28 | */ |
||
29 | protected $errorMessages; |
||
30 | |||
31 | /** |
||
32 | * @var HelperLocator |
||
33 | */ |
||
34 | protected $helper; |
||
35 | |||
36 | /** |
||
37 | * @var AntiCsrfInterface |
||
38 | */ |
||
39 | protected $antiCsrf; |
||
40 | |||
41 | 24 | public function __construct() |
|
44 | |||
45 | 1 | public function __clone() |
|
50 | |||
51 | /** |
||
52 | * @param BuilderInterface $builder |
||
53 | * @param FilterFactory $filterFactory |
||
54 | * @param HelperLocatorFactory $helperFactory |
||
55 | * |
||
56 | * @\Ray\Di\Di\Inject |
||
57 | */ |
||
58 | 24 | public function setBaseDependencies( |
|
67 | |||
68 | 1 | public function setAntiCsrf(AntiCsrfInterface $antiCsrf) |
|
72 | |||
73 | /** |
||
74 | * @\Ray\Di\Di\PostConstruct |
||
75 | */ |
||
76 | 24 | public function postConstruct() |
|
83 | |||
84 | /** |
||
85 | * {@inheritdoc} |
||
86 | */ |
||
87 | 2 | public function input($input) |
|
91 | |||
92 | /** |
||
93 | * {@inheritdoc} |
||
94 | */ |
||
95 | 2 | public function error($input) |
|
110 | |||
111 | /** |
||
112 | * @param array $attr attributes for the form tag |
||
113 | * |
||
114 | * @throws \Aura\Html\Exception\HelperNotFound |
||
115 | * @throws \Aura\Input\Exception\NoSuchInput |
||
116 | * |
||
117 | * @return string |
||
118 | */ |
||
119 | 3 | public function form($attr = []) |
|
128 | |||
129 | /** |
||
130 | * Applies the filter to a subject. |
||
131 | * |
||
132 | * @param array $data |
||
133 | * |
||
134 | * @throws CsrfViolationException |
||
135 | * |
||
136 | * @return bool |
||
137 | */ |
||
138 | 10 | public function apply(array $data) |
|
147 | |||
148 | /** |
||
149 | * Returns all failure messages for all fields. |
||
150 | * |
||
151 | * @return array |
||
152 | */ |
||
153 | 4 | public function getFailureMessages() |
|
157 | |||
158 | /** |
||
159 | * Returns all the fields collection |
||
160 | * |
||
161 | * @return \ArrayIterator |
||
162 | */ |
||
163 | 1 | public function getIterator() |
|
167 | |||
168 | /** |
||
169 | * Return form markup string |
||
170 | * |
||
171 | * @return string |
||
172 | */ |
||
173 | 1 | public function __toString() |
|
186 | } |
||
187 |
Our type inference engine has found a suspicous assignment of a value to a property. This check raises an issue when a value that can be of a given class or a super-class is assigned to a property that is type hinted more strictly.
Either this assignment is in error or an instanceof check should be added for that assignment.