protected function ViewsForm::getFormObject in Drupal 10
Same name and namespace in other branches
- 8 core/modules/views/src/Form/ViewsForm.php \Drupal\views\Form\ViewsForm::getFormObject()
- 9 core/modules/views/src/Form/ViewsForm.php \Drupal\views\Form\ViewsForm::getFormObject()
Returns the object used to build the step form.
Parameters
\Drupal\Core\Form\FormStateInterface $form_state: The form_state of the current form.
Return value
\Drupal\Core\Form\FormInterface The form object to use.
File
- core/
modules/ views/ src/ Form/ ViewsForm.php, line 199
Class
- ViewsForm
- Provides a base class for single- or multistep view forms.
Namespace
Drupal\views\FormCode
protected function getFormObject(FormStateInterface $form_state) {
// If this is a class, instantiate it.
$form_step_class = $form_state
->get([
'step_controller',
$form_state
->get('step'),
]) ?: 'Drupal\\views\\Form\\ViewsFormMainForm';
return $this->classResolver
->getInstanceFromDefinition($form_step_class);
}