protected function DrupalTranslator::getOptions

Returns options suitable for use with t().

2 calls to DrupalTranslator::getOptions()

File

drupal/core/lib/Drupal/Core/Validation/DrupalTranslator.php, line 87
Contains \Drupal\Core\Validation\DrupalTranslator.

Class

DrupalTranslator
Translates strings using Drupal's translation system.

Namespace

Drupal\Core\Validation

Code

protected function getOptions($domain = NULL, $locale = NULL) {

  // We do not support domains, so we ignore this parameter.
  // If locale is left NULL, t() will default to the interface language.
  $locale = isset($locale) ? $locale : $this->locale;
  return array(
    'langcode' => $locale,
  );
}