You are here

public function TranslationsDataCollector::__construct in Devel 8

Same name and namespace in other branches
  1. 8.3 webprofiler/src/DataCollector/TranslationsDataCollector.php \Drupal\webprofiler\DataCollector\TranslationsDataCollector::__construct()
  2. 8.2 webprofiler/src/DataCollector/TranslationsDataCollector.php \Drupal\webprofiler\DataCollector\TranslationsDataCollector::__construct()
  3. 4.x webprofiler/src/DataCollector/TranslationsDataCollector.php \Drupal\webprofiler\DataCollector\TranslationsDataCollector::__construct()

Parameters

\Drupal\Core\StringTranslation\TranslationInterface $translation:

\Drupal\Core\Routing\UrlGeneratorInterface $urlGenerator:

File

webprofiler/src/DataCollector/TranslationsDataCollector.php, line 35

Class

TranslationsDataCollector
Class TranslationsDataCollector

Namespace

Drupal\webprofiler\DataCollector

Code

public function __construct(TranslationInterface $translation, UrlGeneratorInterface $urlGenerator) {
  $this->translation = $translation;
  $this->urlGenerator = $urlGenerator;
  $this->data['translations']['translated'] = [];
  $this->data['translations']['untranslated'] = [];
}