function PluginSettingsBase::setSetting

Same name in other branches
  1. 9 core/lib/Drupal/Core/Field/PluginSettingsBase.php \Drupal\Core\Field\PluginSettingsBase::setSetting()
  2. 10 core/lib/Drupal/Core/Field/PluginSettingsBase.php \Drupal\Core\Field\PluginSettingsBase::setSetting()
  3. 11.x core/lib/Drupal/Core/Field/PluginSettingsBase.php \Drupal\Core\Field\PluginSettingsBase::setSetting()

Overrides PluginSettingsInterface::setSetting

3 calls to PluginSettingsBase::setSetting()
ImageFormatter::onDependencyRemoval in core/modules/image/src/Plugin/Field/FieldFormatter/ImageFormatter.php
Informs the plugin that some configuration it depends on will be deleted.
ImageWidget::onDependencyRemoval in core/modules/image/src/Plugin/Field/FieldWidget/ImageWidget.php
Informs the plugin that some configuration it depends on will be deleted.
TestFieldWidget::onDependencyRemoval in core/modules/field/tests/modules/field_test/src/Plugin/Field/FieldWidget/TestFieldWidget.php
Informs the plugin that some configuration it depends on will be deleted.

File

core/lib/Drupal/Core/Field/PluginSettingsBase.php, line 87

Class

PluginSettingsBase
Base class for the Field API plugins.

Namespace

Drupal\Core\Field

Code

public function setSetting($key, $value) {
    $this->settings[$key] = $value;
    return $this;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.