Summary
Internal accessor methods of some StringConverter implementations were exposed erroneously.
The relevant class hierarchies are:
DateTimeStringConverterDateStringConverterTimeStringConverter
NumberStringConverterCurrencyStringConverterPercentageStringConverter
The method of DateTimeStringConverter was deprecated in JDK-8261092 and removed in JDK-8270855. The methods of the remaining classes were deprecated in JDK-8320615 and are being removed here.
Problem
Internal implementation details are exposed to the user, which can cause fragile reliance as internal code can change.
Solution
Remove the deprecated methods.
Specification
Removed in javafx.util.converter.TimeStringConverter and javafx.util.converter.DateStringConverter:
/**
* @deprecated This method was exposed erroneously and will be removed in a future version.
*/
@Deprecated(forRemoval = true, since = "22")
@Override
protected DateFormat getDateFormat()
Removed in javafx.util.converter.NumberStringConverter:
/**
* Returns a {@code NumberFormat} instance to use for formatting
* and parsing in this {@code StringConverter}.
*
* @return a {@code NumberFormat} instance for formatting and parsing in this
* {@code StringConverter}
* @deprecated This method was exposed erroneously and will be removed in a future version.
*/
@Deprecated(forRemoval = true, since = "22")
protected NumberFormat getNumberFormat()
Removed in javafx.util.converter.CurrencyStringConverter and javafx.util.converter.PercentageStringConverter:
/**
* @deprecated This method was exposed erroneously and will be removed in a future version.
*/
@Deprecated(forRemoval = true, since = "22")
@SuppressWarnings("removal")
@Override
public NumberFormat getNumberFormat()
- csr of
-
JDK-8250802 Refactor StringConverter and its subclasses
-
- Open
-