1 | <?php |
||
30 | class FormObjectProxy |
||
31 | { |
||
32 | /** |
||
33 | * @var FormObject |
||
34 | */ |
||
35 | protected $formObject; |
||
36 | |||
37 | /** |
||
38 | * @var FormInterface |
||
39 | */ |
||
40 | protected $form; |
||
41 | |||
42 | /** |
||
43 | * @var string |
||
44 | */ |
||
45 | protected $formHash; |
||
46 | |||
47 | /** |
||
48 | * @var bool |
||
49 | */ |
||
50 | protected $formWasSubmitted = false; |
||
51 | |||
52 | /** |
||
53 | * @var bool |
||
54 | */ |
||
55 | protected $formWasValidated = false; |
||
56 | |||
57 | /** |
||
58 | * @var FormResult |
||
59 | */ |
||
60 | protected $formResult; |
||
61 | |||
62 | /** |
||
63 | * @var FormObjectRequestData |
||
64 | */ |
||
65 | protected $requestData; |
||
66 | |||
67 | /** |
||
68 | * @var FormObjectMetadata |
||
69 | */ |
||
70 | protected $metadata; |
||
71 | |||
72 | /** |
||
73 | * @var FormObjectSteps |
||
74 | */ |
||
75 | protected $stepService; |
||
76 | |||
77 | /** |
||
78 | * @param FormObject $formObject |
||
79 | * @param FormInterface $form |
||
80 | */ |
||
81 | public function __construct(FormObject $formObject, FormInterface $form) |
||
87 | |||
88 | /** |
||
89 | * @return FormInterface |
||
90 | */ |
||
91 | public function getForm() |
||
95 | |||
96 | /** |
||
97 | * Will mark the form as submitted (change the result returned by the |
||
98 | * function `formWasSubmitted()`). |
||
99 | */ |
||
100 | public function markFormAsSubmitted() |
||
104 | |||
105 | /** |
||
106 | * Returns `true` if the form was submitted by the user. |
||
107 | * |
||
108 | * @return bool |
||
109 | */ |
||
110 | public function formWasSubmitted() |
||
114 | |||
115 | /** |
||
116 | * Marks the form as validated. |
||
117 | */ |
||
118 | public function markFormAsValidated() |
||
122 | |||
123 | /** |
||
124 | * @return bool |
||
125 | */ |
||
126 | public function formWasValidated() |
||
130 | |||
131 | /** |
||
132 | * @return FormResult |
||
133 | */ |
||
134 | public function getFormResult() |
||
142 | |||
143 | /** |
||
144 | * @return FormObjectRequestData |
||
145 | */ |
||
146 | public function getRequestData() |
||
150 | |||
151 | /** |
||
152 | * @return FormMetadata |
||
153 | */ |
||
154 | public function getFormMetadata() |
||
162 | |||
163 | /** |
||
164 | * @return Step|null |
||
165 | */ |
||
166 | public function getCurrentStep() |
||
170 | |||
171 | /** |
||
172 | * @param Request $request |
||
173 | */ |
||
174 | public function fetchCurrentStep(Request $request) |
||
178 | |||
179 | /** |
||
180 | * @return SubstepDefinition |
||
181 | */ |
||
182 | public function getCurrentSubstepDefinition() |
||
186 | |||
187 | /** |
||
188 | * @param SubstepDefinition $currentSubstepDefinition |
||
189 | */ |
||
190 | public function setCurrentSubstepDefinition(SubstepDefinition $currentSubstepDefinition) |
||
194 | |||
195 | /** |
||
196 | * @return FormStepPersistence |
||
197 | */ |
||
198 | public function getStepPersistence() |
||
202 | |||
203 | /** |
||
204 | * @return string |
||
205 | */ |
||
206 | public function getFormHash() |
||
214 | |||
215 | /** |
||
216 | * @param string $hash |
||
217 | */ |
||
218 | public function setFormHash($hash) |
||
222 | |||
223 | /** |
||
224 | * @param FormObjectRequestData $requestData |
||
225 | */ |
||
226 | public function injectRequestData(FormObjectRequestData $requestData) |
||
230 | } |
||
231 |