[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-openjfx-dev
Subject:    [REVIEW] Adding wildcards to cell factory API
From:       richard.bair () oracle ! com (Richard Bair)
Date:       2012-02-14 21:34:55
Message-ID: B8D26FF1-3712-4902-9194-B7639F3CFAF5 () oracle ! com
[Download RAW message or body]

Looks good to me.

On Feb 13, 2012, at 3:09 PM, Jonathan Giles wrote:

> Hi all,
> 
> http://javafx-jira.kenai.com/browse/RT-17692
> 
> I'm hoping to have a discussion around modifying the cell factory API in \
> TableView/TableColumn/ListView/TreeView to allow for the cell factories to produce \
> subclasses of the TableRow/TableCell/ListCell/TreeCell classes respectively. I hope \
> to do this in a compatible manner, but I need feedback from people if their \
> generics-foo is stronger than mine, in case they can sense trouble. 
> In essence, my intention is to take the signature of the TableView rowFactory, for \
> example, and replace it with a version that includes '? extends' for the return \
> type of the Callback. For example, rather than: private \
> ObjectProperty<Callback<TableView<S>, TableRow<S>>> rowFactory; 
> I would like to see:
> private ObjectProperty<Callback<TableView<S>, ? extends TableRow<S>>> rowFactory;
> 
> After changing the property, I would also like to change the signature of the \
> getter/setter/*Property methods to have the same signature. 
> The main driver for this is in relation to custom controls such as TreeTable. In my \
> proof of concept, I had to locally change TableView as above so that I could return \
> the more useful TreeTableRow, rather than the forced-upon-me TableRow. 
> I appreciate your feedback.
> 
> -- 
> -- Jonathan
> 


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic