function LocaleSource::loadSource
Same name and namespace in other branches
- 11.x core/modules/locale/src/LocaleSource.php \Drupal\locale\LocaleSource::loadSource()
Loads a single translation source containing current translation status.
Parameters
string $project_name: The project name.
string $langcode: The language code.
Return value
\Drupal\locale\LocaleTranslationSource The source object.
File
-
core/
modules/ locale/ src/ LocaleSource.php, line 84
Class
- LocaleSource
- Provides the locale source services.
Namespace
Drupal\localeCode
public function loadSource(string $project_name, string $langcode) : LocaleTranslationSource {
return $this->loadSources([
$project_name,
], [
$langcode,
])[$project_name][$langcode];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.