/** * {@inheritdoc} */ public function getName() { if (null === $this->name) { $this->name = parent::getName() . md5($this->rootConfig); } return $this->name; }
/** * Constructor. */ public function __construct(Kernel $kernel) { $this->kernel = $kernel; parent::__construct('Symfony', Kernel::VERSION . ' - ' . $kernel->getName()); $this->definition->addOption(new InputOption('--shell', '-s', InputOption::PARAMETER_NONE, 'Launch the shell.')); if (!$this->kernel->isBooted()) { $this->kernel->boot(); } $this->registerCommands(); }
/** * Collects information about the Symfony kernel. * * @return Value\SymfonyKernelSystemInfo */ public function collect() { ksort($this->bundles, SORT_FLAG_CASE | SORT_STRING); return new Value\SymfonyKernelSystemInfo(['environment' => $this->kernel->getEnvironment(), 'debugMode' => $this->kernel->isDebug(), 'version' => Kernel::VERSION, 'bundles' => $this->bundles, 'rootDir' => $this->kernel->getRootDir(), 'name' => $this->kernel->getName(), 'cacheDir' => $this->kernel->getCacheDir(), 'logDir' => $this->kernel->getLogDir(), 'charset' => $this->kernel->getCharset()]); }