function LocaleTranslationSource::getFile

Returns file for the source.

Return value

\Drupal\locale\File\LocaleFile|null The file for the given source.

File

core/modules/locale/src/LocaleTranslationSource.php, line 109

Class

LocaleTranslationSource
Provides source and translation status information for a project/langcode.

Namespace

Drupal\locale

Code

public function getFile(SourceType $translationSource) : LocaleFile|null {
  return $this->files[$translationSource->value] ?? NULL;
}

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