/** * Boot application console. * * @param KernelEvent $event */ public function boot(KernelEvent $event) { $this->kernel = $event->getKernel(); $this->loadConsoles($event->getKernel()); $this->setExecutor($this->getExecutor($event->getKernel()->getContainer())); $this->run(new ArgvInput()); }
/** * Kernel booting listeners. * * @param KernelEvent $event */ public function onBooted(KernelEvent $event) { $responseEvent = new ResponseEvent($event->getKernel(), $event->getRequest()); $event->getKernel()->fireEvent(KernelEvents::REQUEST, $responseEvent); if (!$responseEvent->hasResponse()) { throw new RuntimeException(sprintf('There are no response found. Did you forgot add a return statement?')); } $responseEvent->getResponse()->send(); }
public function onBooted(KernelEvent $event) { $event->stopPropagation(); $this->responseEvent = new ResponseEvent($event->getKernel(), $event->getRequest()); $event->getKernel()->fireEvent(KernelEvents::REQUEST, $this->responseEvent); }