You are here

protected static function NameBase::t in Plug 7

Parameters

string $string: A string containing the English string to translate.

array $args: An associative array of replacements to make after translation. Based on the first character of the key, the value is escaped and/or themed. See format_string() for details.

array $options: An associative array of additional options, with the following elements:

  • 'langcode' (defaults to the current language): The language code to translate to a language other than what is used to display the page.
  • 'context' (defaults to the empty context): The context the source string belongs to.

Return value

string The translated string.

See also

t().

2 methods override NameBase::t()
AcmeTest::t in modules/plug_example/src/Plugin/name/AcmeTest.php
Overrides NameBase::t().
JohnTest::t in modules/plug_example/src/Plugin/name/JohnTest.php
Overrides NameBase::t().

File

modules/plug_example/src/Plugin/name/NameBase.php, line 56
Contains Drupal\plug_example\Plugin\name\NameBase

Class

NameBase

Namespace

Drupal\plug_example\Plugin\name

Code

protected static function t($string, array $args = array(), array $options = array()) {
  return t($string, $args, $options);
}