Bug 402445 - [Viewers] Add generics to the JFace Viewer framework
Summary: [Viewers] Add generics to the JFace Viewer framework
Status: NEW
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.3   Edit
Hardware: All All
: P3 enhancement with 6 votes (vote)
Target Milestone: ---   Edit
Assignee: Platform-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords: api, helpwanted
: 412273 413973 413974 413975 413978 414072 415561 415573 416343 417724 418190 418192 (view as bug list)
Depends on: 418189 395213 413976 414067 414356 416189 416339 416343 417676 418195 419501
Blocks: 417142
  Show dependency tree
 
Reported: 2013-03-05 10:45 EST by Lars Vogel CLA
Modified: 2019-06-17 10:24 EDT (History)
25 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lars Vogel CLA 2013-03-05 10:45:06 EST
We should add generics support to the JFace Viewers.
Comment 1 Dani Megert CLA 2013-07-17 02:55:55 EDT
See also http://wiki.eclipse.org/Generify_A_Java_Project
Comment 2 Andrey Loskutov CLA 2013-08-29 16:11:08 EDT
See the hot discussion on planned approach at http://dev.eclipse.org/mhonarc/lists/cross-project-issues-dev/msg09647.html with some objections regarding the right way to do it.

One of the problems mentioned by Ed was that arrays don't play nice with generics, but JFace API's (content provider) use arrays as return values.

IMHO the only right way to introduce generics in such "legacy" interfaces:
public Object[] getElements(Object inputElement)
is not to introduce them at all.

There will be no winner after generifying such interfaces. Either one must switch from array types to Collections (and made incompatible API changes) or everyone will see lot of (sometimes unavoidable) warnings after refactoring, in a perfectly valid code.
Comment 3 John Arthorne CLA 2013-08-30 15:05:03 EDT
(In reply to Andrey Loskutov from comment #2)
> One of the problems mentioned by Ed was that arrays don't play nice with
> generics, but JFace API's (content provider) use arrays as return values.

See bug 416189.
Comment 4 John Arthorne CLA 2013-09-05 10:51:26 EDT
Somewhat related, I entered bug 416639 about using covariant return types in JFace viewers.
Comment 5 Lars Vogel CLA 2013-10-10 04:14:27 EDT
Current work is done in a separate branch johna/402445.
Comment 6 Jeanderson Candido CLA 2014-05-25 23:09:06 EDT
Just for information, I'm continuing this work.

As suggested by Lars, I forked the project on Github to work on it without disturbing anyone.

I'm currently applying existing patches by Hendrik from johna/402445.
Comment 7 Lars Vogel CLA 2015-08-14 11:09:03 EDT
*** Bug 414057 has been marked as a duplicate of this bug. ***
Comment 8 Lars Vogel CLA 2015-08-14 11:10:00 EDT
*** Bug 418190 has been marked as a duplicate of this bug. ***
Comment 9 Lars Vogel CLA 2015-08-14 11:10:40 EDT
*** Bug 418192 has been marked as a duplicate of this bug. ***
Comment 10 Lars Vogel CLA 2015-08-14 11:19:19 EDT
*** Bug 412273 has been marked as a duplicate of this bug. ***
Comment 11 Lars Vogel CLA 2015-08-14 11:22:25 EDT
*** Bug 413974 has been marked as a duplicate of this bug. ***
Comment 12 Lars Vogel CLA 2015-08-14 11:23:05 EDT
*** Bug 415573 has been marked as a duplicate of this bug. ***
Comment 13 Lars Vogel CLA 2015-08-14 11:23:32 EDT
*** Bug 415561 has been marked as a duplicate of this bug. ***
Comment 14 Lars Vogel CLA 2015-08-14 11:24:51 EDT
*** Bug 413975 has been marked as a duplicate of this bug. ***
Comment 15 Lars Vogel CLA 2015-08-14 11:25:02 EDT
*** Bug 413978 has been marked as a duplicate of this bug. ***
Comment 16 Lars Vogel CLA 2015-08-14 11:25:34 EDT
*** Bug 413973 has been marked as a duplicate of this bug. ***
Comment 17 Lars Vogel CLA 2015-08-14 11:31:04 EDT
*** Bug 414072 has been marked as a duplicate of this bug. ***
Comment 18 Lars Vogel CLA 2015-08-24 06:15:14 EDT
*** Bug 416343 has been marked as a duplicate of this bug. ***
Comment 19 Lars Vogel CLA 2015-08-24 06:22:26 EDT
*** Bug 417724 has been marked as a duplicate of this bug. ***
Comment 20 Eclipse Genie CLA 2015-08-25 06:41:37 EDT
New Gerrit change created: https://git.eclipse.org/r/54460

WARNING: this patchset contains 3265 new lines of code and may require a Contribution Questionnaire (CQ) if the author is not a committer on the project. Please see:https://wiki.eclipse.org/Project_Management_Infrastructure/Creating_A_Contribution_Questionnaire
Comment 21 Ed Merks CLA 2015-08-25 12:13:56 EDT
Should I interpret this as an effort to push this forward despite the problems, objections, and unaddressed issues in https://bugs.eclipse.org/bugs/show_bug.cgi?id=416189 or is this sandbox activity?
Comment 22 Dani Megert CLA 2015-08-25 12:36:41 EDT
(In reply to Ed Merks from comment #21)
> Should I interpret this as an effort to push this forward despite the
> problems, objections, and unaddressed issues in
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=416189 or is this sandbox
> activity?

I don't know. But for me it is clear that those things must be addressed before committing anything to master.
Comment 23 Lars Vogel CLA 2015-08-25 14:13:00 EDT
(In reply to Ed Merks from comment #21)
> Should I interpret this as an effort to push this forward despite the
> problems, objections, and unaddressed issues in
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=416189 or is this sandbox
> activity?

I'm currently in process for rebasing the generics work onto master and afterwards I plan to look at the remaining open issues including Bug 416189 in which different opinions are expressed about the value of this work.
Comment 24 Markus Keller CLA 2016-02-12 09:20:27 EST
Too late for 4.6, and will probably never happen (for all the reasons already listed here, in dependencies, and elsewhere in mailing lists like https://dev.eclipse.org/mhonarc/lists/platform-ui-dev/msg05459.html ).