class MessageFormatter implements MessageFormatterInterface, ChoiceMessageFormatterInterface

Methods

__construct(MessageSelector $selector = null)

No description

string
format(string $message, string $locale, array $parameters = [])

Formats a localized message pattern with given arguments.

string
choiceFormat(string $message, int $number, string $locale, array $parameters = [])

Formats a localized message pattern with given arguments.

Details

at line 26
__construct(MessageSelector $selector = null)

Parameters

MessageSelector $selector The message selector for pluralization

at line 34
string format(string $message, string $locale, array $parameters = [])

Formats a localized message pattern with given arguments.

Parameters

string $message The message (may also be an object that can be cast to string)
string $locale The message locale
array $parameters An array of parameters for the message

Return Value

string

at line 42
string choiceFormat(string $message, int $number, string $locale, array $parameters = [])

Formats a localized message pattern with given arguments.

Parameters

string $message The message (may also be an object that can be cast to string)
int $number The number to use to find the indice of the message
string $locale The message locale
array $parameters An array of parameters for the message

Return Value

string