Returns a string representation of the LanguageIdentifier part of
[Locale].
See the Rust documentation for id for more information.
Returns a string representation of [Locale] language.
See the Rust documentation for id for more information.
Set the language part of the [Locale].
See the Rust documentation for try_from_str for more information.
Returns a string representation of [Locale] region.
See the Rust documentation for id for more information.
Set the region part of the [Locale].
See the Rust documentation for try_from_str for more information.
Returns a string representation of [Locale] script.
See the Rust documentation for id for more information.
Set the script part of the [Locale]. Pass an empty string to remove the script.
See the Rust documentation for try_from_str for more information.
Clones the [Locale].
See the Rust documentation for Locale for more information.
See the Rust documentation for total_cmp for more information.
See the Rust documentation for strict_cmp for more information.
Returns a string representation of the unicode extension.
See the Rust documentation for extensions for more information.
See the Rust documentation for normalizing_eq for more information.
Returns a string representation of [Locale].
See the Rust documentation for write_to for more information.
StaticfromConstruct an [Locale] from an locale identifier.
This will run the complete locale parsing algorithm. If code size and
performance are critical and the locale is of a known shape (such as
aa-BB) use create_und, set_language, set_script, and set_region.
See the Rust documentation for try_from_str for more information.
StaticnormalizeNormalizes a locale string.
See the Rust documentation for normalize for more information.
StaticunknownConstruct a unknown [Locale] "und".
See the Rust documentation for UNKNOWN for more information.
An ICU4X Locale, capable of representing strings like
"en-US".See the Rust documentation for
Localefor more information.