You are here

public function DrupalKernel::getContainer in Drupal 10

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/DrupalKernel.php \Drupal\Core\DrupalKernel::getContainer()
  2. 9 core/lib/Drupal/Core/DrupalKernel.php \Drupal\Core\DrupalKernel::getContainer()

Gets the current container.

Return value

\Symfony\Component\DependencyInjection\ContainerInterface A ContainerInterface instance.

Overrides DrupalKernelInterface::getContainer

File

core/lib/Drupal/Core/DrupalKernel.php, line 500

Class

DrupalKernel
The DrupalKernel class is the core of Drupal itself.

Namespace

Drupal\Core

Code

public function getContainer() {
  return $this->container;
}