function EntityTypeManager::setContainer
Sets the service container.
Deprecated
in drupal:10.3.0 and is removed from drupal:11.0.0. Instead, you should pass the container as an argument in the __construct() method.
See also
https://www.drupal.org/node/3419963
File
-
core/
lib/ Drupal/ Core/ Entity/ EntityTypeManager.php, line 304
Class
- EntityTypeManager
- Manages entity type plugin definitions.
Namespace
Drupal\Core\EntityCode
public function setContainer(?ContainerInterface $container) : void {
@trigger_error(__METHOD__ . '() is deprecated in drupal:10.3.0 and is removed from drupal:11.0.0. Instead, you should pass the container as an argument in the __construct() method. See https://www.drupal.org/node/3419963', E_USER_DEPRECATED);
$this->container = $container;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.