return [ // {% trans %}Symfony is great!{% endtrans %}
new TransTokenParser(),
// {% trans_default_domain "foobar" %}
new TransDefaultDomainTokenParser(),
];
} public function getNodeVisitors(): array
{ return [$this->
getTranslationNodeVisitor(),
new TranslationDefaultDomainNodeVisitor()];
} public function getTranslationNodeVisitor(): TranslationNodeVisitor
{ return $this->translationNodeVisitor ?:
$this->translationNodeVisitor =
new TranslationNodeVisitor();
} /**
* @param array|string $arguments Can be the locale as a string when $message is a TranslatableInterface
*/
public function trans(string|\Stringable|TranslatableInterface|null
$message, array|string
$arguments =
[], string
$domain = null, string
$locale = null, int
$count = null
): string
{