API Review: Use ObservableNumberValue as parameter for valueAt() methods

Richard Bair richard.bair at oracle.com
Fri Nov 2 13:52:37 PDT 2012


The existing methods would continue to function though, is that right? They wouldn't need to be deprecated from a functional perspective (i.e.: they aren't totally broken), but they're just extra noise in the API?

Richard

On Sep 18, 2012, at 12:19 AM, Michael Heinrichs <michael.heinrichs at oracle.com> wrote:

> Hi,
> 
> currently the various valueAt() methods expect an ObservableIntegerValue for the index. (The valueAt() methods create a binding to request a specific element in an ObservableList.) This is wrong, the type should have been an ObservableNumberValue, because this fits to the general philosophy of the binding API. (In general the binding API tries to loosen the type system as much as possible without dropping the ability to use primitives internally.)
> 
> I want to add new versions of the various valueAt() methods that expect ObservableNumberValue for the index. The current methods will be marked as deprecated and should be removed in a future incompatible update of the JavaFX API.
> 
> Thanks,
> Michael



More information about the openjfx-dev mailing list