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 129653 - [Move Inner to Outer] Cannot move intreface to outer level
Summary: [Move Inner to Outer] Cannot move intreface to outer level
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Refactoring (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Jan Becicka
URL:
Keywords:
: 163745 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-03-10 13:41 UTC by Jiri Prox
Modified: 2010-11-14 06:21 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jiri Prox 2008-03-10 13:41:02 UTC
Product Version: NetBeans IDE Dev (Build 20080310023444)
Java: 1.6.0_04; Java HotSpot(TM) Client VM 10.0-b19
System: SunOS version 5.11 running on x86; UTF-8; en_US (nb)

The interface cannot be move to outer level. Strange errors are shown in the dialog and the refactoring cannot continue.

Steps to reproduce:
1) have two classes:
public class OuterClass {
        
    public Inner1 getInner() {
        return new Inner1();
    }
    
    public class Inner1{
    }
        
    public interface InnerIface {
        void method1();
    }       
}

public class User implements OuterClass.InnerIface {

    public User() {
        OuterClass out = new OuterClass();
        OuterClass.Inner1 in1 =  out.getInner();        
    }    
    
    public void method1() {
    }    
}


2) call move inner to outer on InnerIface

-> dialog contains this errors:
Cannot refactor "out.getInner". Use "Declare Field" option.
Cannot refactor "OuterClass.Inner1". Use "Declare Field" option.
Comment 1 Jiri Prox 2008-04-11 01:47:22 UTC
moving opened issues from TM <= 6.1 to TM=Dev
Comment 2 Jiri Prox 2009-04-27 13:38:10 UTC
*** Issue 163745 has been marked as a duplicate of this issue. ***
Comment 3 Jan Becicka 2010-11-12 10:40:02 UTC
Changeset: http://hg.netbeans.org/jet-main/rev/e73242a9f5c3
Author:    Jan Becicka <jbecicka@netbeans.org>
Date:      2010-11-12 11:22
Message:   Issue #129653 - [Move Inner to Outer] Cannot move intreface to outer level
Comment 4 Quality Engineering 2010-11-14 06:21:04 UTC
Integrated into 'main-golden', will be available in build *201011140001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/e73242a9f5c3
User: Jan Becicka <jbecicka@netbeans.org>
Log: Issue #129653 - [Move Inner to Outer] Cannot move intreface to outer level