interface TranslatorInterface in Zircon Profile 8
Same name in this branch
- 8 vendor/symfony/translation/TranslatorInterface.php \Symfony\Component\Translation\TranslatorInterface
- 8 vendor/symfony/css-selector/XPath/TranslatorInterface.php \Symfony\Component\CssSelector\XPath\TranslatorInterface
- 8 core/lib/Drupal/Core/Validation/TranslatorInterface.php \Drupal\Core\Validation\TranslatorInterface
- 8 core/lib/Drupal/Core/StringTranslation/Translator/TranslatorInterface.php \Drupal\Core\StringTranslation\Translator\TranslatorInterface
Same name and namespace in other branches
- 8.0 core/lib/Drupal/Core/Validation/TranslatorInterface.php \Drupal\Core\Validation\TranslatorInterface
Defines an interface used in validation.
This extends the interface used by the Symfony validator in order to indicate that the Drupal code is actually independent from the Symfony translation component.
Hierarchy
- interface \Symfony\Component\Translation\TranslatorInterface
- interface \Drupal\Core\Validation\TranslatorInterface
Expanded class hierarchy of TranslatorInterface
All classes that implement TranslatorInterface
See also
https://github.com/symfony/symfony/pull/6189
https://github.com/symfony/symfony/issues/15714
3 files declare their use of TranslatorInterface
- ConstraintViolationBuilder.php in core/
lib/ Drupal/ Core/ TypedData/ Validation/ ConstraintViolationBuilder.php - Contains \Drupal\Core\TypedData\Validation\ConstraintViolationBuilder.
- ExecutionContext.php in core/
lib/ Drupal/ Core/ TypedData/ Validation/ ExecutionContext.php - Contains \Drupal\Core\TypedData\Validation\ExecutionContext.
- ExecutionContextFactory.php in core/
lib/ Drupal/ Core/ TypedData/ Validation/ ExecutionContextFactory.php - Contains \Drupal\Core\TypedData\Validation\ExecutionContextFactory.
File
- core/
lib/ Drupal/ Core/ Validation/ TranslatorInterface.php, line 22 - Contains \Drupal\Core\Validation\TranslatorInterface.
Namespace
Drupal\Core\ValidationView source
interface TranslatorInterface extends SymfonyTranslatorInterface {
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
TranslatorInterface:: |
public | function | Returns the current locale. | 6 |
TranslatorInterface:: |
public | function | Sets the current locale. | 6 |
TranslatorInterface:: |
public | function | Translates the given message. | 6 |
TranslatorInterface:: |
public | function | Translates the given choice message by choosing a translation according to a number. | 6 |