Package org.openstreetmap.josm.tools
Class JosmDecimalFormatSymbolsProvider
java.lang.Object
java.util.spi.LocaleServiceProvider
java.text.spi.DecimalFormatSymbolsProvider
org.openstreetmap.josm.tools.JosmDecimalFormatSymbolsProvider
JOSM implementation of the
DecimalFormatSymbols class,
consistent with ISO 80000-1.
This class will only be used with Java 9 and later runtimes, as Java 8 implementation relies
on Java Extension Mechanism only, while Java 9 supports application classpath.
See LocaleServiceProvider javadoc for more details.- Since:
- 12931
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionLocale[]getInstance(Locale locale) static doubleReturns a newdoubleinitialized to the value represented by the specifiedString, allowing both dot and comma decimal separators.Methods inherited from class java.util.spi.LocaleServiceProvider
isSupportedLocale
-
Constructor Details
-
JosmDecimalFormatSymbolsProvider
public JosmDecimalFormatSymbolsProvider()
-
-
Method Details
-
getInstance
- Specified by:
getInstancein classDecimalFormatSymbolsProvider
-
getAvailableLocales
- Specified by:
getAvailableLocalesin classLocaleServiceProvider
-
parseDouble
Returns a newdoubleinitialized to the value represented by the specifiedString, allowing both dot and comma decimal separators.- Parameters:
s- the string to be parsed.- Returns:
- the
doublevalue represented by the string argument. - Throws:
NullPointerException- if the string is nullNumberFormatException- if the string does not contain a parsabledouble.- Since:
- 13050
- See Also:
-