public function FormBuilder::setCache in Drupal 8
Same name and namespace in other branches
- 9 core/lib/Drupal/Core/Form/FormBuilder.php \Drupal\Core\Form\FormBuilder::setCache()
- 10 core/lib/Drupal/Core/Form/FormBuilder.php \Drupal\Core\Form\FormBuilder::setCache()
Stores a form in the cache.
Parameters
string $form_build_id: The unique form build ID.
array $form: The form to cache.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.
Overrides FormCacheInterface::setCache
2 calls to FormBuilder::setCache()
- FormBuilder::processForm in core/
lib/ Drupal/ Core/ Form/ FormBuilder.php - Processes a form submission.
- FormBuilder::rebuildForm in core/
lib/ Drupal/ Core/ Form/ FormBuilder.php - Constructs a new $form from the information in $form_state.
File
- core/
lib/ Drupal/ Core/ Form/ FormBuilder.php, line 458
Class
- FormBuilder
- Provides form building and processing.
Namespace
Drupal\Core\FormCode
public function setCache($form_build_id, $form, FormStateInterface $form_state) {
$this->formCache
->setCache($form_build_id, $form, $form_state);
}