function EntityDeriverBase::__construct

Same name in other branches
  1. 8.x-3.x src/Plugin/Deriver/EntityDeriverBase.php \Drupal\ctools\Plugin\Deriver\EntityDeriverBase::__construct()

Constructs new EntityViewDeriver.

Parameters

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager.

\Drupal\Core\StringTranslation\TranslationInterface $string_translation: The string translation service.

\Drupal\Core\Entity\EntityFieldManagerInterface $entity_field_manager: The entity field manager.

\Drupal\Core\Entity\EntityTypeRepositoryInterface $entity_type_repository: The entity type repository.

File

src/Plugin/Deriver/EntityDeriverBase.php, line 54

Class

EntityDeriverBase
An abstract base class that sets up the needs of entity specific derivers.

Namespace

Drupal\ctools\Plugin\Deriver

Code

public function __construct(EntityTypeManagerInterface $entity_type_manager, TranslationInterface $string_translation, EntityFieldManagerInterface $entity_field_manager, EntityTypeRepositoryInterface $entity_type_repository) {
    $this->entityTypeManager = $entity_type_manager;
    $this->stringTranslation = $string_translation;
    $this->entityFieldManager = $entity_field_manager;
    $this->entityTypeRepository = $entity_type_repository;
}