You are here

interface ReportingHandlerInterface in Content-Security-Policy 8

CSP Reporting Handler interface.

Hierarchy

Expanded class hierarchy of ReportingHandlerInterface

All classes that implement ReportingHandlerInterface

File

src/Plugin/ReportingHandlerInterface.php, line 11

Namespace

Drupal\csp\Plugin
View source
interface ReportingHandlerInterface {

  /**
   * Get the form fields for configuring this reporting handler.
   *
   * @param array $form
   *   The plugin parent form element.
   *
   * @return array
   *   A Form array.
   */
  public function getForm(array $form);

  /**
   * Validate the form fields of this report handler.
   *
   * @param array $form
   *   The form fields for this plugin.
   * @param \Drupal\Core\Form\FormStateInterface $form_state
   *   The submitted form state.
   */
  public function validateForm(array &$form, FormStateInterface $form_state);

  /**
   * Alter the provided policy according to the plugin settings.
   *
   * @param \Drupal\csp\Csp $policy
   *   The policy to alter.
   */
  public function alterPolicy(Csp $policy);

}

Members

Namesort descending Modifiers Type Description Overrides
ReportingHandlerInterface::alterPolicy public function Alter the provided policy according to the plugin settings. 1
ReportingHandlerInterface::getForm public function Get the form fields for configuring this reporting handler. 1
ReportingHandlerInterface::validateForm public function Validate the form fields of this report handler. 1