public function DefaultSingleLazyPluginCollection::addInstanceId in Drupal 10
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/Plugin/DefaultSingleLazyPluginCollection.php \Drupal\Core\Plugin\DefaultSingleLazyPluginCollection::addInstanceId()
- 9 core/lib/Drupal/Core/Plugin/DefaultSingleLazyPluginCollection.php \Drupal\Core\Plugin\DefaultSingleLazyPluginCollection::addInstanceId()
File
- core/
lib/ Drupal/ Core/ Plugin/ DefaultSingleLazyPluginCollection.php, line 93
Class
- DefaultSingleLazyPluginCollection
- Provides a default plugin collection for a plugin type.
Namespace
Drupal\Core\PluginCode
public function addInstanceId($id, $configuration = NULL) {
$this->instanceId = $id;
// Reset the list of instance IDs since there can be only one.
$this->instanceIds = [];
parent::addInstanceId($id, $configuration);
if ($configuration !== NULL) {
$this
->setConfiguration($configuration);
}
}