public function Kernel::__construct

Constructor.

@api

Parameters

string $environment The environment:

Boolean $debug Whether to enable debugging or not:

2 calls to Kernel::__construct()
DrupalKernel::__construct in drupal/core/lib/Drupal/Core/DrupalKernel.php
Constructs a DrupalKernel object.
Kernel::unserialize in drupal/core/vendor/symfony/http-kernel/Symfony/Component/HttpKernel/Kernel.php
1 method overrides Kernel::__construct()
DrupalKernel::__construct in drupal/core/lib/Drupal/Core/DrupalKernel.php
Constructs a DrupalKernel object.

File

drupal/core/vendor/symfony/http-kernel/Symfony/Component/HttpKernel/Kernel.php, line 76

Class

Kernel
The Kernel is the heart of the Symfony system.

Namespace

Symfony\Component\HttpKernel

Code

public function __construct($environment, $debug) {
  $this->environment = $environment;
  $this->debug = (bool) $debug;
  $this->booted = false;
  $this->rootDir = $this
    ->getRootDir();
  $this->name = $this
    ->getName();
  $this->classes = array();
  if ($this->debug) {
    $this->startTime = microtime(true);
  }
  $this
    ->init();
}