You are here

public function DefaultSingleLazyPluginCollection::setConfiguration in Drupal 10

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/Plugin/DefaultSingleLazyPluginCollection.php \Drupal\Core\Plugin\DefaultSingleLazyPluginCollection::setConfiguration()
  2. 9 core/lib/Drupal/Core/Plugin/DefaultSingleLazyPluginCollection.php \Drupal\Core\Plugin\DefaultSingleLazyPluginCollection::setConfiguration()

File

core/lib/Drupal/Core/Plugin/DefaultSingleLazyPluginCollection.php, line 81

Class

DefaultSingleLazyPluginCollection
Provides a default plugin collection for a plugin type.

Namespace

Drupal\Core\Plugin

Code

public function setConfiguration($configuration) {
  $this->configuration = $configuration;
  $plugin = $this
    ->get($this->instanceId);
  if (PluginHelper::isConfigurable($plugin)) {
    $plugin
      ->setConfiguration($configuration);
  }
  return $this;
}