You are here

public function CspSettingsForm::__construct in Content-Security-Policy 8

Constructs a \Drupal\csp\Form\CspSettingsForm object.

Parameters

\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The factory for configuration objects.

\Drupal\csp\LibraryPolicyBuilder $libraryPolicyBuilder: The Library Policy Builder service.

\Drupal\csp\ReportingHandlerPluginManager $reportingHandlerPluginManager: The Reporting Handler Plugin Manger service.

\Drupal\Core\Messenger\MessengerInterface|null $messenger: The Messenger service.

Overrides ConfigFormBase::__construct

File

src/Form/CspSettingsForm.php, line 86

Class

CspSettingsForm
Form for editing Content Security Policy module settings.

Namespace

Drupal\csp\Form

Code

public function __construct(ConfigFactoryInterface $config_factory, LibraryPolicyBuilder $libraryPolicyBuilder, ReportingHandlerPluginManager $reportingHandlerPluginManager, MessengerInterface $messenger) {
  parent::__construct($config_factory);
  $this->libraryPolicyBuilder = $libraryPolicyBuilder;
  $this->reportingHandlerPluginManager = $reportingHandlerPluginManager;
  $this
    ->setMessenger($messenger);
}