Bug 414057 - [Viewers] Add generics to IStructuredSelection
Summary: [Viewers] Add generics to IStructuredSelection
Status: REOPENED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.3   Edit
Hardware: All All
: P3 enhancement with 2 votes (vote)
Target Milestone: ---   Edit
Assignee: Christoph Laeubrich CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 570570
  Show dependency tree
 
Reported: 2013-07-30 14:44 EDT by Hendrik Still CLA
Modified: 2021-01-25 07:09 EST (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hendrik Still CLA 2013-07-30 14:44:10 EDT
The Selection classes as part of the JFace Viewer should support Java Generics.
Comment 1 Jeanderson Candido CLA 2014-07-21 13:32:29 EDT
Added generics support to IStructuredSelection, StructuredSelection, and ITreeSelection. In addition, Snippets 005, 022, and 053 were updated as well:

https://github.com/jeandersonbc/eclipse.platform.ui/commit/20f6894b9f190ee7c58341edeee0bc5cc22f69ab

PS.: Casting the selection is quite annoying and still doesn't help much client code:

IStructuredSelection<MyModel> selection = (IStructuredSelection<MyModel>) viewer.getSelection();
I think this is a little bit related to Bug 402439. I will think about improvements.
Comment 2 Lars Vogel CLA 2015-08-14 11:09:03 EDT
Will be handled via Bug 402445

*** This bug has been marked as a duplicate of bug 402445 ***
Comment 3 Christoph Laeubrich CLA 2021-01-25 07:09:25 EST
Reopen to solve this particular issue "Add generics to IStructuredSelection" independent of any viewer changes or anything else towards "generics for JFace" improvements.