| Methods |
public
|
_(string $message, array $parameters = [], string $domain = null, string $locale = null): string
Translate the given message.
Translate the given message.
Parameters
| $message |
The message to be translated
|
| $parameters |
Array of parameters used to translate message
|
| $domain |
The domain for the message or null to use the default
|
| $locale |
The locale or null to use the default
|
Returns
Implements
|
#
|
protected
|
processMessage(string $definition, array<string, mixed> $parameters = []): string
Return translated string. If parameters is not empty will replace tokens.
Return translated string. If parameters is not empty will replace tokens.
|
#
|
protected
|
processMessagePlural(
non-empty-array<string, string> $definition,
array<string, mixed> $parameters = [],
int $count = 1,
): string
Parameters
| $count |
Requested plural form
|
|
#
|
protected
|
getDefinition(string $message, string $domain, ?string $locale): non-empty-array<string, string>|null
|
#
|
public
|
addDefinitionFromArray(
array<string, string|non-empty-array<string, string>> $data,
string $locale,
string $domain,
): void
|
#
|
public
|
setDefinitionSingle(
string $key,
string|non-empty-array<string, string> $definition,
string $locale = 'en',
string $domain = 'atk',
): $this
Set or Replace a single definition within a domain.
Set or Replace a single definition within a domain.
|
#
|