public function ContainerAwareInterface::setContainer

Sets the Container.

@api

Parameters

ContainerInterface $container A ContainerInterface instance:

2 methods override ContainerAwareInterface::setContainer()
ContainerAware::setContainer in drupal/core/vendor/symfony/dependency-injection/Symfony/Component/DependencyInjection/ContainerAware.php
Sets the Container associated with this Controller.
HtmlPageController::setContainer in drupal/core/lib/Drupal/Core/HtmlPageController.php
Injects the service container used by this object.

File

drupal/core/vendor/symfony/dependency-injection/Symfony/Component/DependencyInjection/ContainerAwareInterface.php, line 30

Class

ContainerAwareInterface
ContainerAwareInterface should be implemented by classes that depends on a Container.

Namespace

Symfony\Component\DependencyInjection

Code

public function setContainer(ContainerInterface $container = null);