You are here

interface QuickFormInterface in farmOS 2.x

Interface for quick forms.

Hierarchy

Expanded class hierarchy of QuickFormInterface

All classes that implement QuickFormInterface

File

modules/core/quick/src/Plugin/QuickForm/QuickFormInterface.php, line 12

Namespace

Drupal\farm_quick\Plugin\QuickForm
View source
interface QuickFormInterface extends PluginInspectionInterface {

  /**
   * Returns the quick form ID.
   *
   * @return string
   *   The quick form ID.
   */
  public function getId();

  /**
   * Returns the quick form label.
   *
   * @return string
   *   The quick form label.
   */
  public function getLabel();

  /**
   * Returns the quick form description.
   *
   * @return string
   *   The quick form description.
   */
  public function getDescription();

  /**
   * Returns the quick form help text.
   *
   * @return string
   *   The quick form help text.
   */
  public function getHelpText();

  /**
   * Returns the list of access permissions for the quick form.
   *
   * @return string[]
   *   An array of permission strings.
   */
  public function getPermissions();

  /**
   * Checks access for the quick form.
   *
   * @param \Drupal\Core\Session\AccountInterface $account
   *   Run access checks for this account.
   *
   * @return \Drupal\Core\Access\AccessResultInterface
   *   The access result.
   */
  public function access(AccountInterface $account);

  /**
   * Form constructor.
   *
   * @param array $form
   *   An associative array containing the structure of the form.
   * @param \Drupal\Core\Form\FormStateInterface $form_state
   *   The current state of the form.
   *
   * @return array
   *   The form structure.
   */
  public function buildForm(array $form, FormStateInterface $form_state);

  /**
   * Form validation handler.
   *
   * @param array $form
   *   An associative array containing the structure of the form.
   * @param \Drupal\Core\Form\FormStateInterface $form_state
   *   The current state of the form.
   */
  public function validateForm(array &$form, FormStateInterface $form_state);

  /**
   * Form submission handler.
   *
   * @param array $form
   *   An associative array containing the structure of the form.
   * @param \Drupal\Core\Form\FormStateInterface $form_state
   *   The current state of the form.
   */
  public function submitForm(array &$form, FormStateInterface $form_state);

}

Members

Namesort descending Modifiers Type Description Overrides
PluginInspectionInterface::getPluginDefinition public function Gets the definition of the plugin implementation. 4
PluginInspectionInterface::getPluginId public function Gets the plugin_id of the plugin instance. 2
QuickFormInterface::access public function Checks access for the quick form. 1
QuickFormInterface::buildForm public function Form constructor. 1
QuickFormInterface::getDescription public function Returns the quick form description. 1
QuickFormInterface::getHelpText public function Returns the quick form help text. 1
QuickFormInterface::getId public function Returns the quick form ID. 1
QuickFormInterface::getLabel public function Returns the quick form label.
QuickFormInterface::getPermissions public function Returns the list of access permissions for the quick form. 1
QuickFormInterface::submitForm public function Form submission handler. 1
QuickFormInterface::validateForm public function Form validation handler. 1