This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 181087

Summary: Java Hint to assign parameter to (new) field
Product: java Reporter: tnleeuw <tnleeuw>
Component: HintsAssignee: Svata Dedic <sdedic>
Status: NEW ---    
Severity: normal CC: markiewb
Priority: P3    
Version: 6.x   
Hardware: PC   
OS: Windows Vista   
Issue Type: ENHANCEMENT Exception Reporter:

Description tnleeuw 2010-02-23 09:21:53 UTC
I would like to see a Java Hint added that, when I have the cursor on a parameter, gives me the option to assign the parameter to a (new) field when I hit alt-enter.

I miss this feature from Eclipse.
Comment 1 Jan Lahoda 2010-04-12 13:04:11 UTC
Hm, such a hint exists for quite a long time and works OK to me - could you please attach a sample class on which it does not work? Thanks.
Comment 2 tnleeuw 2010-04-13 11:21:20 UTC
Hi,

This hint works when in a constructor, but not in a method:


public class ClassA {
    public void setMyField(String myField) {
        
    }
}


If method 'setMyField()' is specified in an interface, and added to the class definition from the interface, then I start my coding with filling in the interface definition methods. Not with specifying the constructor and parameters.
Comment 3 markiewb 2012-05-18 18:58:07 UTC
Also missing this feature from eclipse and it is not available even in 7.2.