]> git.immae.eu Git - github/wallabag/wallabag.git/blob - vendor/symfony/intl/Symfony/Component/Intl/ResourceBundle/LanguageBundleInterface.php
twig implementation
[github/wallabag/wallabag.git] / vendor / symfony / intl / Symfony / Component / Intl / ResourceBundle / LanguageBundleInterface.php
1 <?php
2
3 /*
4 * This file is part of the Symfony package.
5 *
6 * (c) Fabien Potencier <fabien@symfony.com>
7 *
8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code.
10 */
11
12 namespace Symfony\Component\Intl\ResourceBundle;
13
14 /**
15 * Gives access to language-related ICU data.
16 *
17 * @author Bernhard Schussek <bschussek@gmail.com>
18 */
19 interface LanguageBundleInterface extends ResourceBundleInterface
20 {
21 /**
22 * Returns the name of a language.
23 *
24 * @param string $lang A language code (e.g. "en").
25 * @param string|null $region Optional. A region code (e.g. "US").
26 * @param string $locale Optional. The locale to return the name in.
27 * Defaults to {@link \Locale::getDefault()}.
28 *
29 * @return string|null The name of the language or NULL if not found.
30 */
31 public function getLanguageName($lang, $region = null, $locale = null);
32
33 /**
34 * Returns the names of all known languages.
35 *
36 * @param string $locale Optional. The locale to return the names in.
37 * Defaults to {@link \Locale::getDefault()}.
38 *
39 * @return string[] A list of language names indexed by language codes.
40 */
41 public function getLanguageNames($locale = null);
42
43 /**
44 * Returns the name of a script.
45 *
46 * @param string $script A script code (e.g. "Hans").
47 * @param string $lang Optional. A language code (e.g. "zh").
48 * @param string $locale Optional. The locale to return the name in.
49 * Defaults to {@link \Locale::getDefault()}.
50 *
51 * @return string|null The name of the script or NULL if not found.
52 */
53 public function getScriptName($script, $lang = null, $locale = null);
54
55 /**
56 * Returns the names of all known scripts.
57 *
58 * @param string $locale Optional. The locale to return the names in.
59 * Defaults to {@link \Locale::getDefault()}.
60 *
61 * @return string[] A list of script names indexed by script codes.
62 */
63 public function getScriptNames($locale = null);
64 }