Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 353252 - Support dynamic list of child element types
Summary: Support dynamic list of child element types
Status: CLOSED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Sapphire (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Konstantin Komissarchik CLA
QA Contact:
URL:
Whiteboard:
Keywords: plan
Depends on:
Blocks:
 
Reported: 2011-07-27 15:55 EDT by Ling Hao CLA
Modified: 2021-11-19 09:21 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ling Hao CLA 2011-07-27 15:55:58 EDT
In the sapphire-gallery.xml sample, heterogeneous element properties or list properties, I would like to add an @Enablement annotation to IChildElementWithEnum type. Depending on the enablment condition, the "Child element with enum" choice will not appear in heterogeneous element properties and Add -> "Child element with enum" menu option will not be available for the heterogeneous list properties.
Comment 1 Konstantin Komissarchik CLA 2011-07-28 14:17:30 EDT
I think that rather than implementing type enablement, we should look at supporting a dynamic list of possible child element types for element and list properties. 

This would solve this requirement as you would be able to vary the set of possible types based on a criteria and would also enable extensibility where third parties wish to contribute new types to an existing model.
Comment 2 Konstantin Komissarchik CLA 2011-10-12 12:20:41 EDT
This has been implemented for a while now. Somehow the bug hasn't been resolved. See PossibleTypesService in the docs.

Please verify.
Comment 3 Ling Hao CLA 2011-11-28 14:58:37 EST
Verify via sapphire-gallery's custom PossibleTypeService.