Uses of Class
java.util.Locale
Packages that useLocale
Package
Description
Provides a collection of interfaces and classes that compose the Java Accessibility Utilities.
Provides the classes necessary to create an applet and the classes an applet uses to communicate with its applet context.
Contains all of the classes for creating user interfaces and for painting graphics and images.
Provides classes and interfaces for the input method framework.
Provides interfaces that enable the development of input methods that can be used with any Java runtime environment.
Provides classes and interfaces relating to bean context.
Provides for system input and output through data streams, serialization and the file system.
Provides classes that are fundamental to the design of the Java programming language.
Defines charsets, decoders, and encoders, for translating between bytes and Unicode characters.
Provides classes and interfaces for handling text, dates, numbers, and messages in a manner independent of natural languages.
Service provider classes for the classes in the java.text package.
The main API for dates, times, instants, and durations.
Generic API for calendar systems other than the default ISO.
Provides classes to print and parse dates and times.
Access to date and time using fields and units, and date time adjusters.
Contains the collections framework, some internationalization support classes, a service loader, properties, random number generation, string parsing and scanning classes, base64 encoding and decoding, a bit array, and several miscellaneous utility classes.
Service provider classes for the classes in the java.util package.
Defines a contract between user-interface components and an assistive technology that provides access to those components.
Facilities for declaring annotation processors and for allowing annotation processors to communicate with an annotation processing tool environment.
The main package of the Java Image I/O API.
A package of the Java Image I/O API dealing with reading and writing metadata.
Package containing the public classes used by the built-in BMP plug-in.
Classes supporting the built-in JPEG plug-in.
A package of the Java Image I/O API containing the plug-in interfaces for readers, writers, transcoders, and streams, and a runtime registry.
Provides classes and interfaces that describe the types of Java Print Service attributes and how they can be collected into attribute sets.
Package
javax.print.attribute.standard
contains classes for specific printing attributes.This package provides the classes necessary for services to interact with applications in order to retrieve information (authentication data including usernames or passwords, for example) or to display information (error and warning messages, for example).
Provides a set of "lightweight" (all-Java language) components that, to the maximum degree possible, work the same on all platforms.
Provides classes and interfaces for dealing with
javax.swing.JTable
.Provides interfaces for tools which can be invoked from a program, for example, compilers.
Defines XML/Java Type Mappings.
The Doclet API provides an environment which, in conjunction with the Language Model API and Compiler Tree API, allows clients to inspect the source-level structures of programs and libraries, including API comments embedded in the source.
Provides interfaces for creating tools, such as a Read-Eval-Print Loop (REPL), which interactively evaluate "snippets" of Java programming language code.
Provides a mechanism to launch an instance of a Java shell tool.
Provides the interfaces for the Simple API for XML (SAX).
Provides helper classes, including support for bootstrapping SAX-based applications.
Uses ofLocale incom.sun.java.accessibility.util
Methods incom.sun.java.accessibility.util that returnLocaleUses ofLocale injava.applet
Methods injava.applet that returnLocaleUses ofLocale injava.awt
Modifier and TypeMethodDescriptionComponent.AccessibleAWTComponent.getLocale()
Returns the locale of this object.Component.getLocale()
Gets the locale of this component.List.AccessibleAWTList.AccessibleAWTListChild.getLocale()
Gets the locale of the component.MenuComponent.AccessibleAWTMenuComponent.getLocale()
Returns the locale of this object.Window.getLocale()
Gets theLocale
object that is associated with this window, if the locale has been set.Modifier and TypeMethodDescriptionabstractString[]
GraphicsEnvironment.getAvailableFontFamilyNames
(Locale l) Returns an array containing the names of all font families in thisGraphicsEnvironment
localized for the specified locale.Returns the family name of thisFont
, localized for the specified locale.Font.getFontName
(Locale l) Returns the font face name of theFont
, localized for the specified locale.staticComponentOrientation
ComponentOrientation.getOrientation
(Locale locale) Returns the orientation that is appropriate for the given locale.void
Sets the locale of this component.Uses ofLocale injava.awt.im
Methods injava.awt.im that returnLocaleModifier and TypeMethodDescriptionInputContext.getLocale()
Returns the current locale of the current input method or keyboard layout.Methods injava.awt.im with parameters of typeLocaleModifier and TypeMethodDescriptionboolean
InputContext.selectInputMethod
(Locale locale) Attempts to select an input method or keyboard layout that supports the given locale, and returns a value indicating whether such an input method or keyboard layout has been successfully selected.Uses ofLocale injava.awt.im.spi
Methods injava.awt.im.spi that returnLocaleModifier and TypeMethodDescriptionLocale[]
InputMethodDescriptor.getAvailableLocales()
Returns the locales supported by the corresponding input method.InputMethod.getLocale()
Returns the current input locale.Methods injava.awt.im.spi with parameters of typeLocaleModifier and TypeMethodDescriptionInputMethodDescriptor.getInputMethodDisplayName
(Locale inputLocale,Locale displayLanguage) Returns the user-visible name of the corresponding input method for the given input locale in the language in which the name will be displayed.InputMethodDescriptor.getInputMethodIcon
(Locale inputLocale) Returns an icon for the corresponding input method.boolean
Attempts to set the input locale.Uses ofLocale injava.beans.beancontext
Fields injava.beans.beancontext declared asLocaleModifier and TypeFieldDescriptionprotectedLocale
BeanContextSupport.locale
Deprecated, for removal: This API element is subject to removal in a future version.The current locale of this BeanContext.Methods injava.beans.beancontext that returnLocaleModifier and TypeMethodDescriptionBeanContextSupport.getLocale()
Deprecated, for removal: This API element is subject to removal in a future version.Gets the locale for thisBeanContext
.Methods injava.beans.beancontext with parameters of typeLocaleModifier and TypeMethodDescriptionvoid
Deprecated, for removal: This API element is subject to removal in a future version.Sets the locale of this BeanContext.Constructors injava.beans.beancontext with parameters of typeLocaleModifierConstructorDescriptionBeanContextServicesSupport
(BeanContextServices peer,Locale lcle) Deprecated, for removal: This API element is subject to removal in a future version.Create an instance using the specified localeBeanContextServicesSupport
(BeanContextServices peer,Locale lcle, boolean dtime) Deprecated, for removal: This API element is subject to removal in a future version.Create an instance using the specified Locale and design mode.BeanContextServicesSupport
(BeanContextServices peer,Locale lcle, boolean dTime, boolean visible) Deprecated, for removal: This API element is subject to removal in a future version.Construct a BeanContextServicesSupport instanceBeanContextSupport
(BeanContext peer,Locale lcle) Deprecated, for removal: This API element is subject to removal in a future version.Create an instance using the specified localeBeanContextSupport
(BeanContext peer,Locale lcle, boolean dtime) Deprecated, for removal: This API element is subject to removal in a future version.Create an instance using the specified Locale and design mode.BeanContextSupport
(BeanContext peer,Locale lcle, boolean dTime, boolean visible) Deprecated, for removal: This API element is subject to removal in a future version.Construct a BeanContextSupport instanceUses ofLocale injava.io
Modifier and TypeMethodDescriptionWrites a formatted string to this console's output stream using the specified format string and arguments with the specifiedlocale
.Writes a formatted string to this output stream using the specified format string and arguments.Writes a formatted string to this writer using the specified format string and arguments.A convenience method to write a formatted string to this console's output stream using the specified format string and arguments with the specifiedlocale
.A convenience method to write a formatted string to this output stream using the specified format string and arguments.A convenience method to write a formatted string to this writer using the specified format string and arguments.Provides a formatted prompt using the specifiedlocale
, then reads a single line of text from the console.char[]
Console.readPassword
(Locale locale,String format,Object... args) Provides a formatted prompt using the specifiedlocale
, then reads a password or passphrase from the console with echoing disabled.Uses ofLocale injava.lang
Modifier and TypeMethodDescriptionstaticString
Returns a formatted string using the specified locale, format string, and arguments.String.toLowerCase
(Locale locale) Converts all of the characters in thisString
to lower case using the rules of the givenLocale
.String.toUpperCase
(Locale locale) Converts all of the characters in thisString
to upper case using the rules of the givenLocale
.Uses ofLocale injava.nio.charset
Methods injava.nio.charset with parameters of typeLocaleModifier and TypeMethodDescriptionCharset.displayName
(Locale locale) Returns this charset's human-readable name for the given locale.Uses ofLocale injava.text
Modifier and TypeMethodDescriptionstaticLocale[]
BreakIterator.getAvailableLocales()
Returns an array of all locales for which theget*Instance
methods of this class can return localized instances.staticLocale[]
Collator.getAvailableLocales()
Returns an array of all locales for which thegetInstance
methods of this class can return localized instances.staticLocale[]
DateFormat.getAvailableLocales()
Returns an array of all locales for which theget*Instance
methods of this class can return localized instances.staticLocale[]
DateFormatSymbols.getAvailableLocales()
Returns an array of all locales for which thegetInstance
methods of this class can return localized instances.staticLocale[]
DecimalFormatSymbols.getAvailableLocales()
Returns an array of all locales for which thegetInstance
methods of this class can return localized instances.staticLocale[]
ListFormat.getAvailableLocales()
Returns the available locales that support ListFormat.staticLocale[]
NumberFormat.getAvailableLocales()
Returns an array of all locales for which theget*Instance
methods of this class can return localized instances.DecimalFormatSymbols.getLocale()
Returns locale used to create this instance.ListFormat.getLocale()
Returns theLocale
of this ListFormat.MessageFormat.getLocale()
Gets the locale that's used when creating or comparing subformats.Modifier and TypeMethodDescriptionstaticBreakIterator
BreakIterator.getCharacterInstance
(Locale locale) Returns a newBreakIterator
instance forcharacter breaks for the given locale.staticNumberFormat
NumberFormat.getCompactNumberInstance
(Locale locale,NumberFormat.Style formatStyle) Returns a compact number format for the specifiedlocale
andformatStyle
.staticNumberFormat
NumberFormat.getCurrencyInstance
(Locale inLocale) Returns a currency format for the specified locale.static finalDateFormat
DateFormat.getDateInstance
(int style,Locale aLocale) Gets the date formatter with the given formatting style for the given locale.static finalDateFormat
DateFormat.getDateTimeInstance
(int dateStyle, int timeStyle,Locale aLocale) Gets the date/time formatter with the given formatting styles for the given locale.staticCollator
Collator.getInstance
(Locale desiredLocale) Gets the Collator for the desired locale.static finalDateFormatSymbols
DateFormatSymbols.getInstance
(Locale locale) Gets theDateFormatSymbols
instance for the specified locale.static finalDecimalFormatSymbols
DecimalFormatSymbols.getInstance
(Locale locale) Gets theDecimalFormatSymbols
instance for the specified locale.staticListFormat
ListFormat.getInstance
(Locale locale,ListFormat.Type type,ListFormat.Style style) staticNumberFormat
NumberFormat.getInstance
(Locale inLocale) Returns a general-purpose number format for the specified locale.staticNumberFormat
NumberFormat.getIntegerInstance
(Locale inLocale) Returns an integer number format for the specified locale.staticBreakIterator
BreakIterator.getLineInstance
(Locale locale) Returns a newBreakIterator
instance forline breaks for the given locale.staticNumberFormat
NumberFormat.getNumberInstance
(Locale inLocale) Returns a general-purpose number format for the specified locale.staticNumberFormat
NumberFormat.getPercentInstance
(Locale inLocale) Returns a percentage format for the specified locale.staticBreakIterator
BreakIterator.getSentenceInstance
(Locale locale) Returns a newBreakIterator
instance forsentence breaks for the given locale.static finalDateFormat
DateFormat.getTimeInstance
(int style,Locale aLocale) Gets the time formatter with the given formatting style for the given locale.staticBreakIterator
BreakIterator.getWordInstance
(Locale locale) Returns a newBreakIterator
instance forword breaks for the given locale.void
Sets the locale to be used when creating or comparing subformats.ModifierConstructorDescriptionDateFormatSymbols
(Locale locale) Construct a DateFormatSymbols object by loading format data from resources for the given locale.DecimalFormatSymbols
(Locale locale) Create a DecimalFormatSymbols object for the given locale.MessageFormat
(String pattern,Locale locale) Constructs a MessageFormat for the specified locale and pattern.SimpleDateFormat
(String pattern,Locale locale) Constructs aSimpleDateFormat
using the given pattern and the default date format symbols for the given locale.Uses ofLocale injava.text.spi
Methods injava.text.spi with parameters of typeLocaleModifier and TypeMethodDescriptionabstractBreakIterator
BreakIteratorProvider.getCharacterInstance
(Locale locale) Returns a newBreakIterator
instance forcharacter breaks for the given locale.NumberFormatProvider.getCompactNumberInstance
(Locale locale,NumberFormat.Style formatStyle) Returns a newNumberFormat
instance which formats a number in its compact form for the specifiedlocale
andformatStyle
.abstractNumberFormat
NumberFormatProvider.getCurrencyInstance
(Locale locale) Returns a newNumberFormat
instance which formats monetary values for the specified locale.abstractDateFormat
DateFormatProvider.getDateInstance
(int style,Locale locale) Returns a newDateFormat
instance which formats date with the given formatting style for the specified locale.abstractDateFormat
DateFormatProvider.getDateTimeInstance
(int dateStyle, int timeStyle,Locale locale) Returns a newDateFormat
instance which formats date and time with the given formatting style for the specified locale.abstractCollator
CollatorProvider.getInstance
(Locale locale) Returns a newCollator
instance for the specified locale.abstractDateFormatSymbols
DateFormatSymbolsProvider.getInstance
(Locale locale) Returns a newDateFormatSymbols
instance for the specified locale.abstractDecimalFormatSymbols
DecimalFormatSymbolsProvider.getInstance
(Locale locale) Returns a newDecimalFormatSymbols
instance for the specified locale.abstractNumberFormat
NumberFormatProvider.getIntegerInstance
(Locale locale) Returns a newNumberFormat
instance which formats integer values for the specified locale.abstractBreakIterator
BreakIteratorProvider.getLineInstance
(Locale locale) Returns a newBreakIterator
instance forline breaks for the given locale.abstractNumberFormat
NumberFormatProvider.getNumberInstance
(Locale locale) Returns a new general-purposeNumberFormat
instance for the specified locale.abstractNumberFormat
NumberFormatProvider.getPercentInstance
(Locale locale) Returns a newNumberFormat
instance which formats percentage values for the specified locale.abstractBreakIterator
BreakIteratorProvider.getSentenceInstance
(Locale locale) Returns a newBreakIterator
instance forsentence breaks for the given locale.abstractDateFormat
DateFormatProvider.getTimeInstance
(int style,Locale locale) Returns a newDateFormat
instance which formats time with the given formatting style for the specified locale.abstractBreakIterator
BreakIteratorProvider.getWordInstance
(Locale locale) Returns a newBreakIterator
instance forword breaks for the given locale.Uses ofLocale injava.time
Modifier and TypeMethodDescriptionDayOfWeek.getDisplayName
(TextStyle style,Locale locale) Gets the textual representation, such as 'Mon' or 'Friday'.Month.getDisplayName
(TextStyle style,Locale locale) Gets the textual representation, such as 'Jan' or 'December'.ZoneId.getDisplayName
(TextStyle style,Locale locale) Gets the textual representation of the zone, such as 'British Time' or '+02:00'.Uses ofLocale injava.time.chrono
Methods injava.time.chrono with parameters of typeLocaleModifier and TypeMethodDescriptiondefaultString
Chronology.getDisplayName
(TextStyle style,Locale locale) Gets the textual representation of this chronology.defaultString
Era.getDisplayName
(TextStyle style,Locale locale) Gets the textual representation of this era.HijrahEra.getDisplayName
(TextStyle style,Locale locale) Gets the textual representation of this era.JapaneseEra.getDisplayName
(TextStyle style,Locale locale) Gets the textual representation of this era.MinguoEra.getDisplayName
(TextStyle style,Locale locale) Gets the textual representation of this era.ThaiBuddhistEra.getDisplayName
(TextStyle style,Locale locale) Gets the textual representation of this era.staticChronology
Obtains an instance ofChronology
from a locale.Uses ofLocale injava.time.format
Methods injava.time.format that returnLocaleModifier and TypeMethodDescriptionDateTimeFormatter.getLocale()
Gets the locale to be used during formatting.Methods injava.time.format that return types with arguments of typeLocaleModifier and TypeMethodDescriptionDecimalStyle.getAvailableLocales()
Lists all the locales that are supported.Methods injava.time.format with parameters of typeLocaleModifier and TypeMethodDescriptionstaticString
DateTimeFormatterBuilder.getLocalizedDateTimePattern
(String requestedTemplate,Chronology chrono,Locale locale) Returns the formatting pattern for the requested template for a locale and chronology.staticString
DateTimeFormatterBuilder.getLocalizedDateTimePattern
(FormatStyle dateStyle,FormatStyle timeStyle,Chronology chrono,Locale locale) Gets the formatting pattern for date and time styles for a locale and chronology.DateTimeFormatter.localizedBy
(Locale locale) Returns a copy of this formatter with localized values of the locale, calendar, region, decimal style and/or timezone, that supersede values in this formatter.staticDecimalStyle
Obtains the DecimalStyle for the specified locale.staticDateTimeFormatter
Creates a formatter using the specified pattern and locale.DateTimeFormatterBuilder.toFormatter
(Locale locale) Completes this builder by creating theDateTimeFormatter
using the specified locale.DateTimeFormatter.withLocale
(Locale locale) Returns a copy of this formatter with a new locale.Uses ofLocale injava.time.temporal
Methods injava.time.temporal with parameters of typeLocaleModifier and TypeMethodDescriptiondefaultString
TemporalField.getDisplayName
(Locale locale) Gets the display name for the field in the requested locale.staticWeekFields
Obtains an instance ofWeekFields
appropriate for a locale.Uses ofLocale injava.util
Modifier and TypeFieldDescriptionstatic finalLocale
Locale.CANADA
Useful constant for country.static finalLocale
Locale.CANADA_FRENCH
Useful constant for country.static finalLocale
Locale.CHINA
Useful constant for country.static finalLocale
Locale.CHINESE
Useful constant for language.static finalLocale
Locale.ENGLISH
Useful constant for language.static finalLocale
Locale.FRANCE
Useful constant for country.static finalLocale
Locale.FRENCH
Useful constant for language.static finalLocale
Locale.GERMAN
Useful constant for language.static finalLocale
Locale.GERMANY
Useful constant for country.static finalLocale
Locale.ITALIAN
Useful constant for language.static finalLocale
Locale.ITALY
Useful constant for country.static finalLocale
Locale.JAPAN
Useful constant for country.static finalLocale
Locale.JAPANESE
Useful constant for language.static finalLocale
Locale.KOREA
Useful constant for country.static finalLocale
Locale.KOREAN
Useful constant for language.static finalLocale
Locale.PRC
Useful constant for country.static finalLocale
Locale.ROOT
Useful constant for the root locale.static finalLocale
Locale.SIMPLIFIED_CHINESE
Useful constant for language.static finalLocale
Locale.TAIWAN
Useful constant for country.static finalLocale
Locale.TRADITIONAL_CHINESE
Useful constant for language.static finalLocale
Locale.UK
Useful constant for country.static finalLocale
Locale.US
Useful constant for country.Modifier and TypeMethodDescriptionLocale.Builder.build()
Returns an instance ofLocale
obtained from the fields set on this builder.staticLocale
Locale.forLanguageTag
(String languageTag) Returns a locale for the specified IETF BCP 47 language tag string.staticLocale[]
Calendar.getAvailableLocales()
Returns an array of all locales for which thegetInstance
methods of this class can return localized instances.staticLocale[]
Locale.getAvailableLocales()
Returns an array of available locales.staticLocale
Locale.getDefault()
Gets the current value of thedefault locale
for this instance of the Java Virtual Machine.staticLocale
Locale.getDefault
(Locale.Category category) Gets the current value of thedefault locale
for the specified Category for this instance of the Java Virtual Machine.ResourceBundle.Control.getFallbackLocale
(String baseName,Locale locale) Returns aLocale
to be used as a fallback locale for further resource bundle searches by theResourceBundle.getBundle
factory method.ResourceBundle.getLocale()
Returns the locale of this resource bundle.Formatter.locale()
Returns the locale set by the construction of this formatter.Scanner.locale()
Returns this scanner's locale.staticLocale
Locale.lookup
(List<Locale.LanguageRange> priorityList,Collection<Locale> locales) Returns aLocale
instance for the best-matching language tag using the lookup mechanism defined in RFC 4647.staticLocale
Obtains a locale from a language code.staticLocale
Obtains a locale from language and country.staticLocale
Obtains a locale from language, country and variant.Locale.stripExtensions()
Returns a copy of thisLocale
with noextensions.Modifier and TypeMethodDescriptionLocale.availableLocales()
Returns a stream of available locales.Locale.filter
(List<Locale.LanguageRange> priorityList,Collection<Locale> locales) Returns a list of matchingLocale
instances using the filtering mechanism defined in RFC 4647.Locale.filter
(List<Locale.LanguageRange> priorityList,Collection<Locale> locales,Locale.FilteringMode mode) Returns a list of matchingLocale
instances using the filtering mechanism defined in RFC 4647.ResourceBundle.Control.getCandidateLocales
(String baseName,Locale locale) Returns aList
ofLocale
s as candidate locales forbaseName
andlocale
.Modifier and TypeMethodDescriptionWrites a formatted string to this object's destination using the specified locale, format string, and arguments.static finalResourceBundle
Gets a resource bundle using the specified base name and locale, and the caller module.staticResourceBundle
ResourceBundle.getBundle
(String baseName,Locale locale,ClassLoader loader) Gets a resource bundle using the specified base name, locale, and class loader.staticResourceBundle
ResourceBundle.getBundle
(String baseName,Locale targetLocale,ClassLoader loader,ResourceBundle.Control control) Returns a resource bundle using the specified base name, target locale, class loader and control.staticResourceBundle
Gets a resource bundle using the specified base name and locale on behalf of the specified module.static finalResourceBundle
ResourceBundle.getBundle
(String baseName,Locale targetLocale,ResourceBundle.Control control) Returns a resource bundle using the specified base name, target locale and control, and the caller's class loader.ResourceBundle.Control.getCandidateLocales
(String baseName,Locale locale) Returns aList
ofLocale
s as candidate locales forbaseName
andlocale
.Locale.getDisplayCountry
(Locale inLocale) Returns a name for the locale's country that is appropriate for display to the user.Locale.getDisplayLanguage
(Locale inLocale) Returns a name for the locale's language that is appropriate for display to the user.Calendar.getDisplayName
(int field, int style,Locale locale) Returns the string representation of the calendarfield
value in the givenstyle
andlocale
.Currency.getDisplayName
(Locale locale) Gets the name that is suitable for displaying this currency for the specified locale.Locale.getDisplayName
(Locale inLocale) Returns a name for the locale that is appropriate for display to the user.TimeZone.getDisplayName
(boolean daylight, int style,Locale locale) Returns a name in the specifiedstyle
of thisTimeZone
suitable for presentation to the user in the specifiedlocale
.finalString
TimeZone.getDisplayName
(Locale locale) Returns a long standard time name of thisTimeZone
suitable for presentation to the user in the specifiedlocale
.Calendar.getDisplayNames
(int field, int style,Locale locale) Returns aMap
containing all names of the calendarfield
in the givenstyle
andlocale
and their corresponding field values.Locale.getDisplayScript
(Locale inLocale) Returns a name for the locale's script that is appropriate for display to the user.Locale.getDisplayVariant
(Locale inLocale) Returns a name for the locale's variant code that is appropriate for display to the user.ResourceBundle.Control.getFallbackLocale
(String baseName,Locale locale) Returns aLocale
to be used as a fallback locale for further resource bundle searches by theResourceBundle.getBundle
factory method.staticCalendar
Calendar.getInstance
(Locale aLocale) Gets a calendar using the default time zone and specified locale.staticCalendar
Calendar.getInstance
(TimeZone zone,Locale aLocale) Gets a calendar with the specified time zone and locale.staticCurrency
Currency.getInstance
(Locale locale) Returns theCurrency
instance for the country of the given locale.Gets the symbol of this currency for the specified locale.long
ResourceBundle.Control.getTimeToLive
(String baseName,Locale locale) Returns the time-to-live (TTL) value for resource bundles that are loaded under thisResourceBundle.Control
.boolean
ResourceBundle.Control.needsReload
(String baseName,Locale locale,String format,ClassLoader loader,ResourceBundle bundle, long loadTime) Determines if the expiredbundle
in the cache needs to be reloaded based on the loading time given byloadTime
or some other criteria.ResourceBundle.Control.newBundle
(String baseName,Locale locale,String format,ClassLoader loader, boolean reload) Instantiates a resource bundle for the given bundle name of the given format and locale, using the given class loader if necessary.static void
Locale.setDefault
(Locale newLocale) Sets thedefault locale
for this instance of the Java Virtual Machine.static void
Locale.setDefault
(Locale.Category category,Locale newLocale) Sets thedefault locale
for the specified Category for this instance of the Java Virtual Machine.Sets the locale parameter to the givenlocale
.Resets theBuilder
to match the providedlocale
.ResourceBundle.Control.toBundleName
(String baseName,Locale locale) Converts the givenbaseName
andlocale
to the bundle name.Sets this scanner's locale to the specified locale.Modifier and TypeMethodDescriptionLocale.filter
(List<Locale.LanguageRange> priorityList,Collection<Locale> locales) Returns a list of matchingLocale
instances using the filtering mechanism defined in RFC 4647.Locale.filter
(List<Locale.LanguageRange> priorityList,Collection<Locale> locales,Locale.FilteringMode mode) Returns a list of matchingLocale
instances using the filtering mechanism defined in RFC 4647.staticLocale
Locale.lookup
(List<Locale.LanguageRange> priorityList,Collection<Locale> locales) Returns aLocale
instance for the best-matching language tag using the lookup mechanism defined in RFC 4647.ModifierConstructorDescriptionprotected
Constructs a calendar with the specified time zone and locale.Constructs a new formatter with the specified file, charset, and locale.Constructs a new formatter with the specified file, charset, and locale.Formatter
(OutputStream os,String csn,Locale l) Constructs a new formatter with the specified output stream, charset, and locale.Formatter
(OutputStream os,Charset charset,Locale l) Constructs a new formatter with the specified output stream, charset, and locale.Formatter
(Appendable a,Locale l) Constructs a new formatter with the specified destination and locale.Constructs a new formatter with the specified file name, charset, and locale.Constructs a new formatter with the specified file name, charset, and locale.Constructs a new formatter with the specified locale.GregorianCalendar
(Locale aLocale) Constructs aGregorianCalendar
based on the current time in the default time zone with the given locale.GregorianCalendar
(TimeZone zone,Locale aLocale) Constructs aGregorianCalendar
based on the current time in the given time zone with the given locale.Uses ofLocale injava.util.spi
Methods injava.util.spi that returnLocaleModifier and TypeMethodDescriptionabstractLocale[]
LocaleServiceProvider.getAvailableLocales()
Returns an array of all locales for which this locale service provider can provide localized objects or names.Methods injava.util.spi with parameters of typeLocaleModifier and TypeMethodDescriptionReturns aResourceBundle
for the givenbaseName
andlocale
.Returns aResourceBundle
for the given bundle name and locale.abstractString
LocaleNameProvider.getDisplayCountry
(String countryCode,Locale locale) Returns a localized name for the given IETF BCP47 region code (either ISO 3166 country code or UN M.49 area codes) and the given locale that is appropriate for display to the user.abstractString
LocaleNameProvider.getDisplayLanguage
(String languageCode,Locale locale) Returns a localized name for the given IETF BCP47 language code and the given locale that is appropriate for display to the user.abstractString
CalendarNameProvider.getDisplayName
(String calendarType, int field, int value, int style,Locale locale) Returns the string representation (display name) of the calendarfield value
in the givenstyle
andlocale
.CurrencyNameProvider.getDisplayName
(String currencyCode,Locale locale) Returns a name for the currency that is appropriate for display to the user.abstractString
TimeZoneNameProvider.getDisplayName
(String ID, boolean daylight, int style,Locale locale) Returns a name for the given time zone ID that's suitable for presentation to the user in the specified locale.CalendarNameProvider.getDisplayNames
(String calendarType, int field, int style,Locale locale) Returns aMap
containing all string representations (display names) of theCalendar
field
in the givenstyle
andlocale
and their corresponding field values.LocaleNameProvider.getDisplayScript
(String scriptCode,Locale locale) Returns a localized name for the given IETF BCP47 script code and the given locale that is appropriate for display to the user.LocaleNameProvider.getDisplayUnicodeExtensionKey
(String key,Locale locale) Returns a localized name for the givenUnicode extension key, and the given locale that is appropriate for display to the user.LocaleNameProvider.getDisplayUnicodeExtensionType
(String type,String key,Locale locale) Returns a localized name for the givenUnicode extension type, and the given locale that is appropriate for display to the user.abstractString
LocaleNameProvider.getDisplayVariant
(String variant,Locale locale) Returns a localized name for the given variant code and the given locale that is appropriate for display to the user.abstract int
CalendarDataProvider.getFirstDayOfWeek
(Locale locale) Returns the first day of a week in the givenlocale
.TimeZoneNameProvider.getGenericDisplayName
(String ID, int style,Locale locale) Returns a generic name for the given time zoneID
that's suitable for presentation to the user in the specifiedlocale
.abstract int
CalendarDataProvider.getMinimalDaysInFirstWeek
(Locale locale) Returns the minimal number of days required in the first week of a year.abstractString
Gets the symbol of the given currency code for the specified locale.boolean
LocaleServiceProvider.isSupportedLocale
(Locale locale) Returnstrue
if the givenlocale
is supported by this locale service provider.protectedString
AbstractResourceBundleProvider.toBundleName
(String baseName,Locale locale) Returns the bundle name for the givenbaseName
andlocale
that this provider provides.Uses ofLocale injavax.accessibility
Methods injavax.accessibility that returnLocaleModifier and TypeMethodDescriptionabstractLocale
AccessibleContext.getLocale()
Gets the locale of the component.Methods injavax.accessibility with parameters of typeLocaleModifier and TypeMethodDescriptionprotectedString
AccessibleBundle.toDisplayString
(String name,Locale locale) Obtains the key as a localized string.AccessibleBundle.toDisplayString
(Locale locale) Obtains the key as a localized string.Uses ofLocale injavax.annotation.processing
Methods injavax.annotation.processing that returnLocaleUses ofLocale injavax.imageio
Fields injavax.imageio declared asLocaleModifier and TypeFieldDescriptionprotectedLocale[]
ImageReader.availableLocales
An array ofLocale
s which may be used to localize warning messages, ornull
if localization is not supported.protectedLocale[]
ImageWriter.availableLocales
An array ofLocale
s that may be used to localize warning messages and compression setting values, ornull
if localization is not supported.protectedLocale
ImageReader.locale
The currentLocale
to be used for localization, ornull
if none has been set.protectedLocale
ImageWriteParam.locale
ALocale
to be used to localize compression type names and quality descriptions, ornull
to use a defaultLocale
.protectedLocale
ImageWriter.locale
The currentLocale
to be used for localization, ornull
if none has been set.Fields injavax.imageio with type parameters of typeLocaleModifier and TypeFieldDescriptionImageReader.warningLocales
AList
of theLocale
s associated with each currently registeredIIOReadWarningListener
, initialized by default tonull
, which is synonymous with an emptyList
.ImageWriter.warningLocales
AList
ofLocale
s, one for each element ofwarningListeners
, initialized by defaultnull
, which is synonymous with an emptyList
.Methods injavax.imageio that returnLocaleModifier and TypeMethodDescriptionLocale[]
ImageReader.getAvailableLocales()
Returns an array ofLocale
s that may be used to localize warning listeners and compression settings.Locale[]
ImageWriter.getAvailableLocales()
Returns an array ofLocale
s that may be used to localize warning listeners and compression settings.ImageReader.getLocale()
Returns the currently setLocale
, ornull
if none has been set.ImageWriteParam.getLocale()
Returns the currently setLocale
, ornull
if only a defaultLocale
is supported.ImageWriter.getLocale()
Returns the currently setLocale
, ornull
if none has been set.Methods injavax.imageio with parameters of typeLocaleModifier and TypeMethodDescriptionvoid
Sets the currentLocale
of thisImageReader
to the given value.void
Sets the currentLocale
of thisImageWriter
to the given value.Constructors injavax.imageio with parameters of typeLocaleModifierConstructorDescriptionImageWriteParam
(Locale locale) Constructs anImageWriteParam
set to use a givenLocale
.Uses ofLocale injavax.imageio.metadata
Methods injavax.imageio.metadata with parameters of typeLocaleModifier and TypeMethodDescriptionIIOMetadataFormat.getAttributeDescription
(String elementName,String attrName,Locale locale) Returns aString
containing a description of the named attribute, ornull
.IIOMetadataFormatImpl.getAttributeDescription
(String elementName,String attrName,Locale locale) Returns aString
containing a description of the named attribute, ornull
.IIOMetadataFormat.getElementDescription
(String elementName,Locale locale) Returns aString
containing a description of the named element, ornull
.IIOMetadataFormatImpl.getElementDescription
(String elementName,Locale locale) Returns aString
containing a description of the named element, ornull
.Uses ofLocale injavax.imageio.plugins.bmp
Constructors injavax.imageio.plugins.bmp with parameters of typeLocaleModifierConstructorDescriptionBMPImageWriteParam
(Locale locale) Constructs aBMPImageWriteParam
set to use a givenLocale
and with default values for all parameters.Uses ofLocale injavax.imageio.plugins.jpeg
Constructors injavax.imageio.plugins.jpeg with parameters of typeLocaleUses ofLocale injavax.imageio.spi
Methods injavax.imageio.spi with parameters of typeLocaleModifier and TypeMethodDescriptionabstractString
IIOServiceProvider.getDescription
(Locale locale) Returns a brief, human-readable description of this service provider and its associated implementation.Uses ofLocale injavax.print.attribute
Methods injavax.print.attribute that returnLocaleModifier and TypeMethodDescriptionTextSyntax.getLocale()
Returns this text attribute's text string's natural language (locale).Constructors injavax.print.attribute with parameters of typeLocaleModifierConstructorDescriptionprotected
TextSyntax
(String value,Locale locale) Constructs aTextAttribute
with the specified string and locale.Uses ofLocale injavax.print.attribute.standard
Constructors injavax.print.attribute.standard with parameters of typeLocaleModifierConstructorDescriptionDocumentName
(String documentName,Locale locale) Constructs a new document name attribute with the given document name and locale.JobMessageFromOperator
(String message,Locale locale) Constructs a new job message from operator attribute with the given message and locale.Constructs a new job name attribute with the given job name and locale.JobOriginatingUserName
(String userName,Locale locale) Constructs a new job originating user name attribute with the given user name and locale.OutputDeviceAssigned
(String deviceName,Locale locale) Constructs a new output device assigned attribute with the given device name and locale.PrinterInfo
(String info,Locale locale) Constructs a new printer info attribute with the given information string and locale.PrinterLocation
(String location,Locale locale) Constructs a new printer location attribute with the given location and locale.PrinterMakeAndModel
(String makeAndModel,Locale locale) Constructs a new printer make and model attribute with the given make and model string and locale.PrinterMessageFromOperator
(String message,Locale locale) Constructs a new printer message from operator attribute with the given message and locale.PrinterName
(String printerName,Locale locale) Constructs a new printer name attribute with the given name and locale.RequestingUserName
(String userName,Locale locale) Constructs a new requesting user name attribute with the given user name and locale.Uses ofLocale injavax.security.auth.callback
Methods injavax.security.auth.callback that returnLocaleMethods injavax.security.auth.callback with parameters of typeLocaleUses ofLocale injavax.swing
Methods injavax.swing that returnLocaleModifier and TypeMethodDescriptionstaticLocale
JComponent.getDefaultLocale()
Returns the default locale used to initialize each JComponent's locale property upon creation.UIDefaults.getDefaultLocale()
Returns the default locale.ImageIcon.AccessibleImageIcon.getLocale()
Returns the locale of this object.JList.AccessibleJList.AccessibleJListChild.getLocale()
JTable.AccessibleJTable.AccessibleJTableCell.getLocale()
Gets the locale of the component.JTree.AccessibleJTree.AccessibleJTreeNode.getLocale()
Gets the locale of the component.ProgressMonitor.AccessibleProgressMonitor.getLocale()
Gets the locale of the component.Methods injavax.swing with parameters of typeLocaleModifier and TypeMethodDescriptionReturns the value for key associated with the given locale.staticObject
Returns an object from the defaults that is appropriate for the given locale.boolean
UIDefaults.getBoolean
(Object key,Locale l) If the value ofkey
for the givenLocale
is boolean, return the boolean value, otherwise return false.static boolean
UIManager.getBoolean
(Object key,Locale l) Returns a boolean from the defaults which is associated with the key value and the givenLocale
.If the value ofkey
for the givenLocale
is aBorder
return it, otherwise returnnull
.staticBorder
Returns a border from the defaults that is appropriate for the given locale.If the value ofkey
for the givenLocale
is aColor
return it, otherwise returnnull
.staticColor
Returns a color from the defaults that is appropriate for the given locale.UIDefaults.getDimension
(Object key,Locale l) If the value ofkey
for the givenLocale
is aDimension
return it, otherwise returnnull
.staticDimension
UIManager.getDimension
(Object key,Locale l) Returns a dimension from the defaults that is appropriate for the given locale.If the value ofkey
for the givenLocale
is aFont
return it, otherwise returnnull
.staticFont
Returns a font from the defaults that is appropriate for the given locale.If the value ofkey
for the givenLocale
is anIcon
return it, otherwise returnnull
.staticIcon
Returns anIcon
from the defaults that is appropriate for the given locale.If the value ofkey
for the givenLocale
is anInsets
return it, otherwise returnnull
.staticInsets
Returns anInsets
object from the defaults that is appropriate for the given locale.int
If the value ofkey
for the givenLocale
is anInteger
return its integer value, otherwise return 0.static int
Returns an integer from the defaults that is appropriate for the given locale.If the value ofkey
for the givenLocale
is aString
return it, otherwise returnnull
.staticString
Returns a string from the defaults that is appropriate for the given locale.static void
JComponent.setDefaultLocale
(Locale l) Sets the default locale used to initialize each JComponent's locale property upon creation.void
UIDefaults.setDefaultLocale
(Locale l) Sets the default locale.Uses ofLocale injavax.swing.table
Methods injavax.swing.table that returnLocaleUses ofLocale injavax.tools
Methods injavax.tools with parameters of typeLocaleModifier and TypeMethodDescriptionDiagnostic.getMessage
(Locale locale) Returns a localized message for the given locale.DocumentationTool.getStandardFileManager
(DiagnosticListener<? superJavaFileObject> diagnosticListener,Locale locale,Charset charset) Returns a new instance of the standard file manager implementation for this tool.JavaCompiler.getStandardFileManager
(DiagnosticListener<? superJavaFileObject> diagnosticListener,Locale locale,Charset charset) Returns a new instance of the standard file manager implementation for this tool.void
Sets the locale to be applied when formatting diagnostics and other localized data.void
Sets the locale to be applied when formatting diagnostics and other localized data.Uses ofLocale injavax.xml.datatype
Methods injavax.xml.datatype with parameters of typeLocaleModifier and TypeMethodDescriptionabstractGregorianCalendar
XMLGregorianCalendar.toGregorianCalendar
(TimeZone timezone,Locale aLocale,XMLGregorianCalendar defaults) Convert thisXMLGregorianCalendar
along with provided parameters to aGregorianCalendar
instance.Uses ofLocale injdk.javadoc.doclet
Methods injdk.javadoc.doclet that returnLocaleMethods injdk.javadoc.doclet with parameters of typeLocaleUses ofLocale injdk.jshell
Methods injdk.jshell with parameters of typeLocaleModifier and TypeMethodDescriptionabstractString
Diag.getMessage
(Locale locale) Returns a localized message for the given locale.Uses ofLocale injdk.jshell.tool
Methods injdk.jshell.tool with parameters of typeLocaleModifier and TypeMethodDescriptionSet the locale.Uses ofLocale inorg.xml.sax
Methods inorg.xml.sax with parameters of typeLocaleUses ofLocale inorg.xml.sax.helpers
Methods inorg.xml.sax.helpers with parameters of typeLocale