function FormInterface::buildForm

Same name and namespace in other branches
  1. 9 core/lib/Drupal/Core/Form/FormInterface.php \Drupal\Core\Form\FormInterface::buildForm()
  2. 8.9.x core/lib/Drupal/Core/Form/FormInterface.php \Drupal\Core\Form\FormInterface::buildForm()
  3. 11.x core/lib/Drupal/Core/Form/FormInterface.php \Drupal\Core\Form\FormInterface::buildForm()

Form constructor.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

Return value

array The form structure.

25 methods override FormInterface::buildForm()
BasicForm::buildForm in core/tests/Drupal/Tests/Core/Entity/EntityResolverManagerTest.php
Form constructor.
BasicFormNoContainerInjectionInterface::buildForm in core/tests/Drupal/Tests/Core/Entity/EntityResolverManagerTest.php
Form constructor.
BasicFormNoUpcasting::buildForm in core/tests/Drupal/Tests/Core/Entity/EntityResolverManagerTest.php
Form constructor.
ClearCacheForm::buildForm in core/modules/system/src/Form/ClearCacheForm.php
Form constructor.
ConfigFormBase::buildForm in core/lib/Drupal/Core/Form/ConfigFormBase.php
Form constructor.

... See full list

File

core/lib/Drupal/Core/Form/FormInterface.php, line 35

Class

FormInterface
Provides an interface for a Form.

Namespace

Drupal\Core\Form

Code

public function buildForm(array $form, FormStateInterface $form_state);

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.