You are here

interface CheckSettingsInterface in Security Review 8

Interface for check-specific settings and forms for altering them.

Hierarchy

Expanded class hierarchy of CheckSettingsInterface

All classes that implement CheckSettingsInterface

File

src/CheckSettingsInterface.php, line 8

Namespace

Drupal\security_review
View source
interface CheckSettingsInterface {

  /**
   * Gets a check-specific setting value identified by $key.
   *
   * @param string $key
   *   The key.
   * @param mixed $default_value
   *   Default value to return in case $key does not exist.
   *
   * @return mixed
   *   The value of the stored setting.
   */
  public function get($key, $default_value);

  /**
   * Sets a check-specific setting value identified by $key.
   *
   * @param string $key
   *   The key.
   * @param mixed $value
   *   The new value.
   *
   * @return CheckSettingsInterface
   *   Returns itself.
   */
  public function set($key, $value);

  /**
   * Form constructor.
   *
   * @return array
   *   The form structure.
   */
  public function buildForm();

  /**
   * Form validation handler.
   *
   * @param array $form
   *   An associative array containing the structure of the form.
   * @param array $values
   *   The current values of the form.
   */
  public function validateForm(array &$form, array $values);

  /**
   * Form submission handler.
   *
   * @param array $form
   *   An associative array containing the structure of the form.
   * @param array $values
   *   The current values of the form.
   */
  public function submitForm(array &$form, array $values);

}

Members

Namesort descending Modifiers Type Description Overrides
CheckSettingsInterface::buildForm public function Form constructor. 1
CheckSettingsInterface::get public function Gets a check-specific setting value identified by $key. 1
CheckSettingsInterface::set public function Sets a check-specific setting value identified by $key. 1
CheckSettingsInterface::submitForm public function Form submission handler. 1
CheckSettingsInterface::validateForm public function Form validation handler. 1