12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061 |
- <?php
- namespace Symfony\Component\Intl\ResourceBundle;
- use Symfony\Component\Intl\Data\Provider\LocaleDataProvider;
- use Symfony\Component\Intl\Exception\MissingResourceException;
- class LocaleBundle extends LocaleDataProvider implements LocaleBundleInterface
- {
-
- public function getLocales()
- {
- try {
- return parent::getLocales();
- } catch (MissingResourceException $e) {
- return array();
- }
- }
-
- public function getLocaleName($locale, $displayLocale = null)
- {
- try {
- return $this->getName($locale, $displayLocale);
- } catch (MissingResourceException $e) {
- return;
- }
- }
-
- public function getLocaleNames($displayLocale = null)
- {
- try {
- return $this->getNames($displayLocale);
- } catch (MissingResourceException $e) {
- return array();
- }
- }
- }
|