Source of file ContainerBuilderDebugDumpPass.php
Size: 1,181 Bytes - Last Modified: 2013-07-17T08:22:21+02:00
/home/theseer/Downloads/Symfony/vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Compiler/ContainerBuilderDebugDumpPass.php
123456789101112131415161718192021222324252627282930313233343536373839 | <?php /* * This file is part of the Symfony package. * * (c) Fabien Potencier <fabien@symfony.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Bundle\FrameworkBundle\DependencyInjection\Compiler; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\DependencyInjection\Dumper\XmlDumper; use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; use Symfony\Component\Filesystem\Filesystem; /** * Dumps the ContainerBuilder to a cache file so that it can be used by * debugging tools such as the container:debug console command. * * @author Ryan Weaver <ryan@thatsquality.com> * @author Fabien Potencier <fabien@symfony.com> */ class ContainerBuilderDebugDumpPass implements CompilerPassInterface { public function process(ContainerBuilder $container) { $dumper = new XmlDumper($container); $filesystem = new Filesystem(); $filesystem->dumpFile( $container->getParameter('debug.container.dump'), $dumper->dump(), 0666 & ~umask() ); } } |