Exemplo n.º 1
0
 /**
  * {@inheritdoc}
  */
 public function boot(Application $application)
 {
     $container = $application->getKernel()->getContainer();
     if ($container->has($this->service)) {
         $application->setDispatcher($container->get($this->service));
     }
 }
Exemplo n.º 2
0
 /**
  * {@inheritdoc}
  */
 public function boot(Application $application)
 {
     $container = $application->getKernel()->getContainer();
     if ($container->has($this->service)) {
         $registry = $container->get($this->service);
         foreach ($registry as $command) {
             $application->add($command);
         }
     }
 }