You are here

public function LoggingTranslator::setLocale in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/translation/LoggingTranslator.php \Symfony\Component\Translation\LoggingTranslator::setLocale()

Sets the current locale.

Parameters

string $locale The locale:

Throws

\InvalidArgumentException If the locale contains invalid characters

Overrides TranslatorInterface::setLocale

File

vendor/symfony/translation/LoggingTranslator.php, line 70

Class

LoggingTranslator
@author Abdellatif Ait boudad <a.aitboudad@gmail.com>

Namespace

Symfony\Component\Translation

Code

public function setLocale($locale) {
  $this->translator
    ->setLocale($locale);
}