Home | History | Annotate | Download | only in util

Lines Matching refs:subtag

89  *   language codes in the IANA Language Subtag Registry (search for
104 * valid script codes in the IANA Language Subtag Registry (search
119 * IANA Language Subtag Registry (search for "Type: region"). The
142 * in the IANA Language Subtag Registry (search for "Type: variant").
153 * <dd>Well-formed variant values have the form <code>SUBTAG
154 * (('_'|'-') SUBTAG)*</code> where <code>SUBTAG =
172 * <code>SUBTAG ('-' SUBTAG)*</code> where for the key 'x'
173 * <code>SUBTAG = [0-9a-zA-Z]{1,8}</code> and for other keys
174 * <code>SUBTAG = [0-9a-zA-Z]{2,8}</code> (that is, 'x' allows
182 * in the IANA Language Subtag Registry, the <code>Locale</code> class
219 * <code>[0-9a-zA-Z]{3,8}</code> (it is a single subtag with the same
220 * form as a locale type subtag).
298 * non-wildcard subtag in the language range will appear in every one of the
335 * <p>If multiple language tags match as a result of the subtag {@code '*'}
468 * codes as specified in the IANA Language Subtag Registry. For
722 * @param language An ISO 639 alpha-2 or alpha-3 language code, or a language subtag
754 * @param language An ISO 639 alpha-2 or alpha-3 language code, or a language subtag
779 * @param language An ISO 639 alpha-2 or alpha-3 language code, or a language subtag
1422 * (delimited by '-' or '_') is emitted as a subtag. Otherwise:
1428 * the private use subtag. The first appended subtag will be
1437 * emitted as a private use subtag as above (even if the remainder
1462 * will return "xx-YY", but the language subtag "xx" and the
1463 * region subtag "YY" are invalid because they are not registered
1464 * in the IANA Language Subtag Registry.
1478 String subtag = tag.getLanguage();
1479 if (subtag.length() > 0) {
1480 buf.append(LanguageTag.canonicalizeLanguage(subtag));
1483 subtag = tag.getScript();
1484 if (subtag.length() > 0) {
1486 buf.append(LanguageTag.canonicalizeScript(subtag));
1489 subtag = tag.getRegion();
1490 if (subtag.length() > 0) {
1492 buf.append(LanguageTag.canonicalizeRegion(subtag));
1508 subtag = tag.getPrivateuse();
1509 if (subtag.length() > 0) {
1515 buf.append(subtag);
1531 * the first such subtag and all following subtags are ignored. Compare
1543 * <li>The portion of a private use subtag prefixed by "lvariant",
1546 * empty, the private use subtag is discarded:
1559 * <li>When the languageTag argument contains an extlang subtag,
1560 * the first such subtag is used as the language, and the primary
1561 * language subtag and other extlang subtags are ignored:
1635 * IANA Language Subtag Registry (search for "Type: grandfathered").
2023 for (String subTag : subTags) {
2024 if (!isValidVariantSubtag(subTag)) {
2032 private static boolean isValidVariantSubtag(String subTag) {
2036 if (subTag.length() >= 5 && subTag.length() <= 8) {
2037 if (isAsciiAlphaNum(subTag)) {
2040 } else if (subTag.length() == 4) {
2041 final char firstChar = subTag.charAt(0);
2042 if ((firstChar >= '0' && firstChar <= '9') && isAsciiAlphaNum(subTag)) {
2289 * language subtag in lower case. (See <a href="java/util/Locale.html#getLanguage()">getLanguage()</a>)
2291 * country subtag in upper case. (See <a href="java/util/Locale.html#getCountry()">getCountry()</a>)
2297 * script subtag in title case (See <a href="java/util/Locale.html#getScript()">getScript()</a>)
2495 * subtag to be 5 to 8 alphanumerics or a single numeric followed by 3
2660 * satisfies the IETF BCP 47 variant subtag's syntax requirements,
2951 * subtag {@code "*"} is treated as a language range {@code "*"}. For
2953 * not the first subtag, {@code "*"} and extra {@code "-"} are removed.
3021 * Note that no validation is done against the IANA Language Subtag
3037 * Language Subtag Registry at time of construction.
3079 private static boolean isSubtagIllFormed(String subtag,
3081 if (subtag.equals("") || subtag.length() > 8) {
3083 } else if (subtag.equals("*")) {
3086 char[] charArray = subtag.toCharArray();
3126 * Language Subtag Registry.
3157 * Subtag Registry. For example, if the given {@code ranges} is
3234 * Language Subtag Registry.