Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 311939 - JavaClassImpl.getMethodElementSignatures method returning incorrect results
Summary: JavaClassImpl.getMethodElementSignatures method returning incorrect results
Status: RESOLVED FIXED
Alias: None
Product: WTP Java EE Tools
Classification: WebTools
Component: jst.jem (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows Vista
: P3 normal (vote)
Target Milestone: 3.2 RC1   Edit
Assignee: Aidyl Kareh CLA
QA Contact: Chuck Bridgham CLA
URL:
Whiteboard: PMC_approved
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-06 13:28 EDT by Aidyl Kareh CLA
Modified: 2010-05-13 23:13 EDT (History)
5 users (show)

See Also:
david_williams: pmc_approved+
amkareh: pmc_approved? (raghunathan.srinivasan)
amkareh: pmc_approved? (naci.dai)
amkareh: pmc_approved? (deboer)
amkareh: pmc_approved? (neil.hauge)
amkareh: pmc_approved? (kaloyan)
jsholl: review+
cbridgha: review+


Attachments
Patch (1.24 KB, patch)
2010-05-06 13:33 EDT, Aidyl Kareh CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Aidyl Kareh CLA 2010-05-06 13:28:12 EDT
Build Identifier: WTP 3.2

The JavaClassImpl.getMethodElementSignatures() method is currently returning an extra signature for each method name that has more than one method defined with the same method name. For example, if the class contains methods 'method()' and 'method(long)' then the values returned are 'method', 'method()' and 'method(long)'.

Reproducible: Always
Comment 1 Aidyl Kareh CLA 2010-05-06 13:33:40 EDT
Created attachment 167349 [details]
Patch

Patch fixes JavaClassImpl.getMethodElementSignatures() method so that the extra element is no longer added.
Comment 2 Chuck Bridgham CLA 2010-05-06 14:56:38 EDT
approved
Comment 3 Aidyl Kareh CLA 2010-05-06 17:44:44 EDT
* Explain why you believe this is a stop-ship defect. Or, if it is a "hotbug" (requested by an adopter) please document it as such. 

The JavaClassImpl.getMethodElementSignatures() method is returning an incorrect List of method signatures since it contains additional values. This function is used by an adopter and should be fixed to work correctly.

    * Is there a work-around? If so, why do you believe the work-around is insufficient? 

No

    * How has the fix been tested? Is there a test case attached to the bugzilla record? Has a JUnit Test been added? 

Tested method on different scenarios and classes.

    * Give a brief technical overview. Who has reviewed this fix? 

The getMethodElementSignatures() method is currently returning an extra signature for each method name that has more than one method defined with the same method name (see comment 1 for an example). Chuck, and Jason have reviewed this patch.

    * What is the risk associated with this fix? 

I believe the risk is minimal since it modifies a single get method.
Comment 4 David Williams CLA 2010-05-06 22:15:32 EDT
I'm ok with this one, but in future, please better explain impact to user. I have a hard time telling from the description if a function "breaks" ... user can't do what they meant to ... or if it just looks confusing. In the weeks to come, that distinction will make a difference. 

Thanks,
Comment 5 Jason Sholl CLA 2010-05-07 11:00:32 EDT
code checked into head for 32 RC1