W3cubDocs

/Symfony 2.7

Symfony\Component\Intl\ResourceBundle\RegionBundleInterface

interface RegionBundleInterface implements ResourceBundleInterface

Gives access to region-related ICU data.

Methods

string[] getLocales()

Returns the list of locales that this bundle supports.

from ResourceBundleInterface
string|null getCountryName(string $country, string $displayLocale = null)

Returns the name of a country.

string[] getCountryNames(string $displayLocale = null)

Returns the names of all known countries.

Details

public string[] getLocales()

Returns the list of locales that this bundle supports.

Return Value

string[] A list of locale codes.

public string|null getCountryName(string $country, string $displayLocale = null)

Returns the name of a country.

Parameters

string $country A country code (e.g. "US").
string $displayLocale Optional. The locale to return the name in. Defaults to {@link \Locale::getDefault()}.

Return Value

string|null The name of the country or NULL if not found.

public string[] getCountryNames(string $displayLocale = null)

Returns the names of all known countries.

Parameters

string $displayLocale Optional. The locale to return the names in. Defaults to {@link \Locale::getDefault()}.

Return Value

string[] A list of country names indexed by country codes.

© 2004–2016 Fabien Potencier
Licensed under the MIT License.
http://api.symfony.com/2.7/Symfony/Component/Intl/ResourceBundle/RegionBundleInterface.html