You are here

abstract protected function FormController::getFormObject in Drupal 10

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/Controller/FormController.php \Drupal\Core\Controller\FormController::getFormObject()
  2. 9 core/lib/Drupal/Core/Controller/FormController.php \Drupal\Core\Controller\FormController::getFormObject()

Returns the object used to build the form.

Parameters

\Drupal\Core\Routing\RouteMatchInterface $route_match: The route match.

string $form_arg: Either a class name or a service ID.

Return value

\Drupal\Core\Form\FormInterface The form object to use.

1 call to FormController::getFormObject()
FormController::getContentResult in core/lib/Drupal/Core/Controller/FormController.php
Invokes the form and returns the result.
4 methods override FormController::getFormObject()
HtmlEntityFormController::getFormObject in core/lib/Drupal/Core/Entity/HtmlEntityFormController.php
Instead of a class name or service ID, $form_arg will be a string representing the entity and operation being performed. Consider the following route:
HtmlFormController::getFormObject in core/lib/Drupal/Core/Controller/HtmlFormController.php
Returns the object used to build the form.
LayoutBuilderDecorationTestHtmlEntityFormController::getFormObject in core/modules/layout_builder/tests/modules/layout_builder_decoration_test/src/Controller/LayoutBuilderDecorationTestHtmlEntityFormController.php
Returns the object used to build the form.
LayoutBuilderHtmlEntityFormController::getFormObject in core/modules/layout_builder/src/Controller/LayoutBuilderHtmlEntityFormController.php
Returns the object used to build the form.

File

core/lib/Drupal/Core/Controller/FormController.php, line 107

Class

FormController
Common base class for form interstitial controllers.

Namespace

Drupal\Core\Controller

Code

protected abstract function getFormObject(RouteMatchInterface $route_match, $form_arg);