Bug 105324

Summary: [refactoring] Constructor/Method Params to Setters Refactoring
Product: [Eclipse Project] JDT Reporter: Chris Morris <eclipse>
Component: UIAssignee: JDT-UI-Inbox <jdt-ui-inbox>
Status: ASSIGNED --- QA Contact:
Severity: enhancement    
Priority: P4 CC: daniel_megert
Version: 3.1   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Chris Morris CLA 2005-07-27 11:02:22 EDT
This came out of a discussion on
https://bugs.eclipse.org/bugs/show_bug.cgi?id=102287 which is a request to add
an Introduce Parameter Object refactoring.

102287 talks about a way to help do the Introduce Param Object refactoring
currently by making an anonymous inner class, then using the Convert Anonymous
to Nested refactoring. 

I did this in some of my code and was left with the following:

new IMethodFormattingTester("myMethod", "S,i", (new String[] {"QString;","I"}),
"MyClass").doTest();

It would be nice to then refactor this long param constructor into setters,
something like this:

IMethodFormattingTester tester = new IMethodFormattingTester();
tester.setMethodName = "myMethod";
tester.setExpectedParams = "S,i";
tester.setParams = (new String[] {"QString;","I"});
tester.setClassName = "MyClass";
tester.doTest();