You are here

public function RecipientTypeBase::setConfiguration in Workbench Email 2.x

Same name and namespace in other branches
  1. 8 src/Plugin/RecipientTypeBase.php \Drupal\workbench_email\Plugin\RecipientTypeBase::setConfiguration()

Sets the configuration for this plugin instance.

Parameters

array $configuration: An associative array containing the plugin's configuration.

Overrides ConfigurableInterface::setConfiguration

4 calls to RecipientTypeBase::setConfiguration()
EmailField::setFields in src/Plugin/RecipientType/EmailField.php
Sets roles.
FixedEmail::submitConfigurationForm in src/Plugin/RecipientType/FixedEmail.php
Form submission handler.
RecipientTypeBase::__construct in src/Plugin/RecipientTypeBase.php
Constructs a \Drupal\Component\Plugin\PluginBase object.
Role::setRoles in src/Plugin/RecipientType/Role.php
Sets roles.

File

src/Plugin/RecipientTypeBase.php, line 58

Class

RecipientTypeBase
Provides a base class for Recipient type plugins.

Namespace

Drupal\workbench_email\Plugin

Code

public function setConfiguration(array $configuration) {
  if (isset($configuration['status'])) {
    $this->status = (bool) $configuration['status'];
  }
  if (isset($configuration['settings'])) {
    $this->settings = (array) $configuration['settings'];
  }
  return $this;
}