Defines a chained translation implementation combining multiple translators.
Hierarchy
- class \Drupal\Core\StringTranslation\TranslationManager implements TranslationInterface, TranslatorInterface
File
- core/lib/Drupal/Core/StringTranslation/TranslationManager.php, line 11
Namespace
Drupal\Core\StringTranslation
Members
| Name | Modifiers | Type | Description |
|---|---|---|---|
| TranslationManager::$defaultLangcode | protected | property | The default langcode used in translations. |
| TranslationManager::$sortedTranslators | protected | property | An array of translators, sorted by priority. |
| TranslationManager::$translators | protected | property | An unsorted array of arrays of active translators. |
| TranslationManager::addTranslator | public | function | Appends a translation system to the translation chain. |
| TranslationManager::doTranslate | protected | function | Translates a string to the current language or to a given language. |
| TranslationManager::formatPlural | public | function | Formats a string containing a count of items. Overrides TranslationInterface::formatPlural |
| TranslationManager::getStringTranslation | public | function | Retrieves English string to given language. Overrides TranslatorInterface::getStringTranslation |
| TranslationManager::reset | public | function | Resets translation cache. Overrides TranslatorInterface::reset |
| TranslationManager::setDefaultLangcode | public | function | Sets the default langcode. |
| TranslationManager::sortTranslators | protected | function | Sorts translators according to priority. |
| TranslationManager::translate | public | function | Translates a string to the current language or to a given language. Overrides TranslationInterface::translate |
| TranslationManager::translateString | public | function | Translates a TranslatableMarkup object to a string. Overrides TranslationInterface::translateString |
| TranslationManager::__construct | public | function | Constructs a TranslationManager object. |
Please login to continue.