/** * {@inheritdoc} */ public function setKernel(KernelInterface $kernel) { $this->kernel = $kernel; if (null === self::$sharedKernel) { self::$sharedKernel = clone $kernel; self::$sharedKernel->boot(); } }
/** * @return RouterInterface */ protected function getRouter() { if (null === self::$router) { self::$router = $this->getService('router'); } return self::$router; }