function EntityController::__construct

Same name and namespace in other branches
  1. 11.x core/lib/Drupal/Core/Entity/Controller/EntityController.php \Drupal\Core\Entity\Controller\EntityController::__construct()
  2. 10 core/lib/Drupal/Core/Entity/Controller/EntityController.php \Drupal\Core\Entity\Controller\EntityController::__construct()
  3. 9 core/lib/Drupal/Core/Entity/Controller/EntityController.php \Drupal\Core\Entity\Controller\EntityController::__construct()
  4. 8.9.x core/lib/Drupal/Core/Entity/Controller/EntityController.php \Drupal\Core\Entity\Controller\EntityController::__construct()

Constructs a new EntityController.

File

core/lib/Drupal/Core/Entity/Controller/EntityController.php, line 41

Class

EntityController
Provides the add-page and title callbacks for entities.

Namespace

Drupal\Core\Entity\Controller

Code

public function __construct(protected readonly EntityTypeManagerInterface $entityTypeManager, protected readonly EntityTypeBundleInfoInterface $entityTypeBundleInfo, protected readonly EntityRepositoryInterface $entityRepository, protected readonly RendererInterface $renderer, TranslationInterface $stringTranslation, protected readonly UrlGeneratorInterface $urlGenerator, protected readonly RouteMatchInterface $routeMatch) {
  $this->stringTranslation = $stringTranslation;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.