You are here

public function LingotekContentTranslationHandler::__construct in Lingotek Translation 8

Same name and namespace in other branches
  1. 8.2 src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  2. 4.0.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  3. 3.0.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  4. 3.1.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  5. 3.2.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  6. 3.3.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  7. 3.4.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  8. 3.5.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  9. 3.6.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  10. 3.7.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()
  11. 3.8.x src/LingotekContentTranslationHandler.php \Drupal\lingotek\LingotekContentTranslationHandler::__construct()

Initializes an instance of the content translation controller.

Parameters

\Drupal\Core\Entity\EntityTypeInterface $entity_type: The info array of the given entity type.

\Drupal\Core\Language\LanguageManagerInterface $language_manager: The language manager.

\Drupal\Core\Entity\EntityManagerInterface $entity_manager: The entity manager.

File

src/LingotekContentTranslationHandler.php, line 66
Contains \Drupal\content_translation\ContentTranslationHandler.

Class

LingotekContentTranslationHandler

Namespace

Drupal\lingotek

Code

public function __construct(EntityTypeInterface $entity_type, LanguageManagerInterface $language_manager, EntityManagerInterface $entity_manager) {
  $this->entityTypeId = $entity_type
    ->id();
  $this->entityType = $entity_type;
  $this->languageManager = $language_manager;
  $this->fieldStorageDefinitions = $entity_manager
    ->getLastInstalledFieldStorageDefinitions($this->entityTypeId);
}