null parameter constructors in StringConverters

Nir Lisker nlisker at gmail.com
Mon Aug 18 17:46:01 UTC 2025


Hi all,

In DateTimeStringConverter, NumberStringConverter, and their subclasses,
null parameters sent to the constructors are internally converted to
default values. This is not specified, but it's how the implementation
behaves. I'm working on some changes there and was thinking about changing
the behavior to throw NPEs as it makes no sense to pass null into these and
it's probably a bug more than anything.

The LocalDate/Time converters specified the null-friendly behavior in their
docs even though it doesn't make much sense there either.

Are we allowed to change this?

- Nir
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/openjfx-dev/attachments/20250818/bbccf8df/attachment-0001.htm>


More information about the openjfx-dev mailing list