Symfony\Component\HttpKernel\Bundle\Bundle::boot PHP Méthode

boot() public méthode

Boots the Bundle.
public boot ( )
    public function boot()
    {
    }

Usage Example

Exemple #1
0
 public function boot()
 {
     parent::boot();
     $this->configure();
     if (function_exists('ppm_log')) {
         //In an environment like PPM with several workers Propel's not distributed cache will
         //lead to inconsistent states across all workers, so we need to disable it here completely.
         //Jarves already caches using a distributed cache where all workers are notified when
         //a change changes, so we don't really need Propel's cache here.
         Propel::disableInstancePooling();
     }
     if (!$this->booted) {
         /** @var ContainerInterface $container */
         $container = $this->container;
         /** @var $jarves Jarves */
         $jarves = $container->get('jarves');
         /** @var JarvesConfig $jarvesConfig */
         $jarvesConfig = $container->get('jarves.config');
         $twig = $container->get('twig');
         $twig->addGlobal('jarves_content_render', $container->get('jarves.content.render'));
         $twig->addGlobal('pageStack', $container->get('jarves.page_stack'));
         if ($jarvesConfig->getSystemConfig()->getLogs(true)->isActive()) {
             /** @var $logger \Symfony\Bridge\Monolog\Logger */
             $logger = $container->get('logger');
             $logger->pushHandler($container->get('jarves.logger.handler'));
         }
     }
     $this->booted = true;
 }
All Usage Examples Of Symfony\Component\HttpKernel\Bundle\Bundle::boot