BaseFormIdInterface.php 572 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12
<?php

/**
 * @file
 * Contains \Drupal\Core\Form\BaseFormIdInterface.
 */

namespace Drupal\Core\Form;

/**
 * Provides an interface for a Form that has a base form ID.
 *
13
 * This will become the $form_state->getBaseInfo()['base_form_id'] used to
14 15 16 17 18 19 20
 * generate the name of hook_form_BASE_FORM_ID_alter().
 */
interface BaseFormIdInterface extends FormInterface {

  /**
   * Returns a string identifying the base form.
   *
21 22
   * @return string|null
   *   The string identifying the base form or NULL if this is not a base form.
23 24 25 26
   */
  public function getBaseFormID();

}