class PluginManagerPass
Registers plugin managers to the plugin.cache_clearer service.
Hierarchy
- class \Drupal\Core\Plugin\PluginManagerPass implements \Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface
Expanded class hierarchy of PluginManagerPass
1 file declares its use of PluginManagerPass
- CoreServiceProvider.php in core/
lib/ Drupal/ Core/ CoreServiceProvider.php
File
-
core/
lib/ Drupal/ Core/ Plugin/ PluginManagerPass.php, line 11
Namespace
Drupal\Core\PluginView source
class PluginManagerPass implements CompilerPassInterface {
/**
* {@inheritdoc}
*/
public function process(ContainerBuilder $container) : void {
foreach ($container->getDefinitions() as $service_id => $definition) {
if (str_starts_with($service_id, 'plugin.manager.') && !$definition->hasTag('plugin_manager_cache_clear')) {
if (is_subclass_of($definition->getClass(), '\\Drupal\\Component\\Plugin\\Discovery\\CachedDiscoveryInterface')) {
$definition->addTag('plugin_manager_cache_clear');
}
}
}
}
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overriden Title |
---|---|---|---|---|
PluginManagerPass::process | public | function | You can modify the container here before it is dumped to PHP code. | Overrides CompilerPassInterface::process |