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

Bug 326563

Summary: Allow access to elementType in ConnectionCreationTool
Product: [Modeling] GMF-Runtime Reporter: Lidija Grahek <lgrahek>
Component: GeneralAssignee: Lidija Grahek <lgrahek>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: ahunter.eclipse
Version: unspecified   
Target Milestone: 1.5.0   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Patch
none
Patch none

Description Lidija Grahek CLA 2010-09-29 13:34:41 EDT
org.eclipse.gmf.runtime.diagram.ui.tools.ConnectionCreationTool has protected method getElementType() to return elementType associated with that tool. CreationTool (used for shapes), on the other hand, has the same method, but with public access. ConnectionCreationTool should also allow public access to its elementType.
Comment 1 Lidija Grahek CLA 2010-09-29 13:40:40 EDT
Created attachment 179873 [details]
Patch
Comment 2 Lidija Grahek CLA 2010-09-29 13:42:52 EDT
Attached the patch. For API compatibility, instead of just changing "protected" to "public" for getElementTyoe(), added a new public method to return getElementType().

Anthony, if it looks OK, I will commit it to to HEAD and R1_4_maintenance.
Comment 3 Anthony Hunter CLA 2010-09-30 11:54:13 EDT
Does API tooling not complain with an error that you have added a new method and thus broken API compatibility? (i.e. update the plug-in version to 1.5.) .

Please verify and if this is the case we cannot change in 1.4.2, only HEAD.
Comment 4 Lidija Grahek CLA 2010-09-30 15:39:34 EDT
Created attachment 179993 [details]
Patch

API tooling does complain about added API, so I can't commit this to the maintenance stream. Since that's the case, I attached the patch that changes visibility of getElementType() method from protected to public, and increases version from 1.4.1 to 1.5.0. It will go to HEAD only.
Comment 5 Lidija Grahek CLA 2010-10-14 12:50:19 EDT
Delivered to HEAD.