PHP Interface Yasumi\TranslationsInterface

Exibir arquivo Open project: azuyalabs/yasumi Interface Usage Examples

Public Methods

Method Description
getTranslation ( string $shortName, string $locale ) : string | null Returns translation for holiday in specific locale.
getTranslations ( string $shortName ) : array Returns all available translations for holiday.

Method Details

getTranslation() public method

Returns translation for holiday in specific locale.
public getTranslation ( string $shortName, string $locale ) : string | null
$shortName string holiday short name
$locale string locale
return string | null translated holiday name

getTranslations() public method

Returns all available translations for holiday.
public getTranslations ( string $shortName ) : array
$shortName string holiday short name
return array holiday name translations ['' => '', ...]