class BootstrapCompilerPass

Namespace

Drush\Symfony

Hierarchy

  • class BootstrapCompilerPass implements \Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface

Expanded class hierarchy of BootstrapCompilerPass

Members

Contains filters are case sensitive

File

lib/Drush/Symfony/BootstrapCompilerPass.php, line 9

View source
class BootstrapCompilerPass implements CompilerPassInterface {
  public function process(ContainerBuilder $container) {
    if (!$container->has('bootstrap.manager')) {
      return;
    }

    $definition = $container->findDefinition('bootstrap.manager');

    $taggedServices = $container->findTaggedServiceIds('bootstrap.boot');
    foreach ($taggedServices as $id => $tags) {
      $definition->addMethodCall('add', array(new Reference($id)));
    }
  }
}