Interface TranslatorAwareInterface

Summary

Fully Qualified Name: Laminas\I18n\Translator\TranslatorAwareInterface

Description

Methods

Name Description Defined By
getTranslator() Returns translator used in object TranslatorAwareInterface
getTranslatorTextDomain() Return the translation text domain TranslatorAwareInterface
hasTranslator() Checks if the object has a translator TranslatorAwareInterface
isTranslatorEnabled() Returns whether translator is enabled and should be used TranslatorAwareInterface
setTranslator() Sets translator to use in helper TranslatorAwareInterface
setTranslatorEnabled() Sets whether translator is enabled and should be used TranslatorAwareInterface
setTranslatorTextDomain() Set translation text domain TranslatorAwareInterface

Method Details

getTranslator()

Returns translator used in object

Returns: \TranslatorInterface|null

getTranslatorTextDomain()

Return the translation text domain

Returns: string

hasTranslator()

Checks if the object has a translator

Returns: bool

isTranslatorEnabled()

Returns whether translator is enabled and should be used

Returns: bool

setTranslator()

Sets translator to use in helper

Parameter Name Type Description
$translator \TranslatorInterface|null Default
$textDomain string|null Default

Returns: $this

setTranslatorEnabled()

Sets whether translator is enabled and should be used

Parameter Name Type Description
$enabled bool [optional]

Returns: $this

setTranslatorTextDomain()

Set translation text domain

Parameter Name Type Description
$textDomain string

Returns: $this

Top