protected function SearchPluginCollection::initializePlugin in Drupal 8
Same name and namespace in other branches
- 9 core/modules/search/src/Plugin/SearchPluginCollection.php \Drupal\search\Plugin\SearchPluginCollection::initializePlugin()
Initializes and stores a plugin.
Parameters
string $instance_id: The ID of the plugin instance to initialize.
Overrides DefaultSingleLazyPluginCollection::initializePlugin
File
- core/
modules/ search/ src/ Plugin/ SearchPluginCollection.php, line 50
Class
- SearchPluginCollection
- Provides a container for lazily loading search plugins.
Namespace
Drupal\search\PluginCode
protected function initializePlugin($instance_id) {
parent::initializePlugin($instance_id);
$plugin_instance = $this->pluginInstances[$instance_id];
if ($plugin_instance instanceof ConfigurableSearchPluginInterface) {
$plugin_instance
->setSearchPageId($this->searchPageId);
}
}