Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 324554

Summary: Diagram generation is incomplete for model extensions
Product: z_Archived Reporter: Vincent Zurczak <vincent.zurczak>
Component: ScaAssignee: Project Inbox <stp.sca-inbox>
Status: NEW --- QA Contact:
Severity: normal    
Priority: P3    
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Vincent Zurczak CLA 2010-09-06 05:00:37 EDT
Create a composite file by hand.
Add it an extended element, e.g. a JBI binding.
Then, right-click it and ask to generate a composite diagram.
A diagram is generated, but the JBI binding has a buggy image.

In fact, the visual ID for this item was not resolved.
The error is in the class "org.eclipse.stp.sca.diagram.extension.view.factories.ElementViewFactory", in the method "int getVisualId(View view)".

In fact, we ven get a NPE because of this.
It seems the extended elements are not recognized by EMF ElementTypeRegistry. A default IElementType is returned, and this element cannot be associated with anything in the binding map.

A fix could be to change the map keys, to work with class names, instead of EMF types.