4 * This file is part of the Symfony package.
6 * (c) Fabien Potencier <fabien@symfony.com>
8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code.
12 namespace Symfony\Component\DependencyInjection\Compiler;
14 use Symfony\Component\DependencyInjection\ContainerBuilder;
17 * A pass to automatically process extensions if they implement
18 * CompilerPassInterface.
20 * @author Wouter J <wouter@wouterj.nl>
22 class ExtensionCompilerPass implements CompilerPassInterface
27 public function process(ContainerBuilder $container)
29 foreach ($container->getExtensions() as $extension) {
30 if (!$extension instanceof CompilerPassInterface) {
34 $extension->process($container);