diff --git a/src/java.base/share/classes/java/util/Locale.java b/src/java.base/share/classes/java/util/Locale.java index 2bab271a489..f600afbb007 100644 --- a/src/java.base/share/classes/java/util/Locale.java +++ b/src/java.base/share/classes/java/util/Locale.java @@ -79,9 +79,10 @@ import sun.util.locale.provider.TimeZoneNameUtility; * the number should be formatted according to the customs and conventions of the * user's native country, region, or culture. * - *

The {@code Locale} class implements IETF BCP 47 which is composed of - * RFC 4647 "Matching of Language - * Tags" and RFC 5646 "Tags + *

The {@code Locale} class implements + * IETF BCP 47 which contains + * RFC 4647 "Matching of Language + * Tags" and RFC 5646 "Tags * for Identifying Languages" with support for the LDML (UTS#35, "Unicode * Locale Data Markup Language") BCP 47-compatible extensions for locale data * exchange. Each {@code Locale} is associated with locale data which is provided @@ -101,7 +102,7 @@ import sun.util.locale.provider.TimeZoneNameUtility; *

* {@code Locale} implements IETF BCP 47 and any deviations should be observed * by the comments prefixed by "BCP 47 deviation:". - * RFC 5646 + * RFC 5646 * combines subtags from various ISO (639, 3166, 15924) standards which are also * included in the composition of {@code Locale}. * Additionally, the full list of valid codes for each field can be found in the @@ -120,7 +121,7 @@ import sun.util.locale.provider.TimeZoneNameUtility; * *

Syntax: Well-formed {@code language} values have the form {@code [a-zA-Z]{2,8}}.
*
BCP 47 deviation: this is not the full BCP 47 language production, since it excludes - * extlang + * extlang * (as modern three-letter language codes are preferred).
* *
Example: "en" (English), "ja" (Japanese), "kok" (Konkani)
@@ -208,7 +209,7 @@ import sun.util.locale.provider.TimeZoneNameUtility; * * * BCP 47 deviation: BCP47 defines the following two levels of - * conformance, + * conformance, * "valid" and "well-formed". A valid tag requires that it is well-formed, its * subtag values are registered in the IANA Language Subtag Registry, and it does not * contain duplicate variant or extension singleton subtags. The {@code Locale} @@ -222,8 +223,10 @@ import sun.util.locale.provider.TimeZoneNameUtility; * *

Unicode BCP 47 U Extension

* - *

UTS#35, "Unicode Locale Data Markup Language" defines optional - * attributes and keywords to override or refine the default behavior + *

UTS#35, "Unicode Locale Data Markup Language" defines the + * Unicode BCP 47 U Extension, + * an extension based on RFC 6067, + * which describes optional attributes and keywords to override or refine the default behavior * associated with a locale. A keyword is represented by a pair of * key and type. For example, "nu-thai" indicates that Thai local * digits (value:"thai") should be used for formatting numbers @@ -410,7 +413,7 @@ import sun.util.locale.provider.TimeZoneNameUtility; * with "locale" in the following locale matching documentation. * *

In order to match a user's preferred locales to a set of language - * tags, RFC 4647 Matching of + * tags, RFC 4647 Matching of * Language Tags defines two mechanisms: filtering and lookup. * Filtering is used to get all matching locales, whereas * lookup is to select the best matching locale. @@ -546,6 +549,8 @@ import sun.util.locale.provider.TimeZoneNameUtility; * this mapping, so that resources can be named using either convention, * see {@link ResourceBundle.Control}. * + * @spec https://www.rfc-editor.org/info/bcp47 + * IETF BCP 47 * @spec https://www.rfc-editor.org/info/rfc4647 * RFC 4647: Matching of Language Tags * @spec https://www.rfc-editor.org/info/rfc5646 @@ -2985,7 +2990,7 @@ public final class Locale implements Cloneable, Serializable { /** * This enum provides constants to select a filtering mode for locale - * matching. Refer to RFC 4647 + * matching. Refer to RFC 4647 * Matching of Language Tags for details. * *

As an example, think of two Language Priority Lists each of which @@ -3122,7 +3127,7 @@ public final class Locale implements Cloneable, Serializable { /** * This class expresses a Language Range defined in - * RFC 4647 Matching of + * RFC 4647 Matching of * Language Tags. A language range is an identifier which is used to * select language tag(s) meeting specific requirements by using the * mechanisms described in {@linkplain Locale##LocaleMatching Locale