sfCultureInfo
in package
Table of Contents
Methods
- __construct() : mixed
- __toString() : string
- getCountries() : array<string|int, mixed>
- Get country names for the current culture.
- getCulture() : string
- getDateTimeFormat() : sfDateTimeFormatInfo|null
- Get the date/time format info.
- getInstance() : static
- Get a singleton instance for the given culture.
- getLanguage() : string
- Get the language component of the culture.
- getLanguages() : array<string|int, mixed>
- Get language names for the current culture.
- getName() : string
- Get the display name for this culture.
- getNumberFormat() : sfNumberFormatInfo|null
- Get the number format info.
- getRegion() : string|null
- Get the region/country component of the culture.
Methods
__construct()
public
__construct([string $culture = 'en' ]) : mixed
Parameters
- $culture : string = 'en'
-
Culture code (e.g., 'en', 'en_US')
__toString()
public
__toString() : string
Return values
stringgetCountries()
Get country names for the current culture.
public
getCountries() : array<string|int, mixed>
Return values
array<string|int, mixed> —Country code => country name
getCulture()
public
getCulture() : string
Return values
stringgetDateTimeFormat()
Get the date/time format info.
public
getDateTimeFormat() : sfDateTimeFormatInfo|null
Return values
sfDateTimeFormatInfo|nullgetInstance()
Get a singleton instance for the given culture.
public
static getInstance([string|null $culture = null ]) : static
Parameters
- $culture : string|null = null
Return values
staticgetLanguage()
Get the language component of the culture.
public
getLanguage() : string
Return values
stringgetLanguages()
Get language names for the current culture.
public
getLanguages() : array<string|int, mixed>
Return values
array<string|int, mixed> —Language code => language name
getName()
Get the display name for this culture.
public
getName() : string
Return values
stringgetNumberFormat()
Get the number format info.
public
getNumberFormat() : sfNumberFormatInfo|null
Return values
sfNumberFormatInfo|nullgetRegion()
Get the region/country component of the culture.
public
getRegion() : string|null