You are here

public function HttpPurgerFormBase::buildForm in Generic HTTP Purger 8

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.

Overrides PluginConfigFormBase::buildForm

File

src/Form/HttpPurgerFormBase.php, line 127

Class

HttpPurgerFormBase
Abstract form base for HTTP based configurable purgers.

Namespace

Drupal\purge_purger_http\Form

Code

public function buildForm(array $form, FormStateInterface $form_state) {
  $settings = HttpPurgerSettings::load($this
    ->getId($form_state));
  $form['tabs'] = [
    '#type' => 'vertical_tabs',
    '#weight' => 10,
  ];
  $this
    ->buildFormMetadata($form, $form_state, $settings);
  $this
    ->buildFormRequest($form, $form_state, $settings);
  $this
    ->buildFormHeaders($form, $form_state, $settings);
  $this
    ->buildFormBody($form, $form_state, $settings);
  $this
    ->buildFormPerformance($form, $form_state, $settings);
  $this
    ->buildFormTokensHelp($form, $form_state, $settings);
  $this
    ->buildFormSuccessResolution($form, $form_state, $settings);
  return parent::buildForm($form, $form_state);
}