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

Bug 337887

Summary: [type hierarchy] MethodOverrideTester and Type Hierarchy don't consider flags etc.
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: UIAssignee: Markus Keller <markus.kell.r>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: rthakkar
Version: 3.7   
Target Milestone: 3.7 M6   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Attachments:
Description Flags
Fix none

Description Markus Keller CLA 2011-02-22 14:24:13 EST
Created attachment 189532 [details]
Fix

HEAD

MethodOverrideTester and the Type Hierarchy don't consider flags (private, static) and don't rule out constructors.

Example:

package javadoc;
public class Outer {

    /**
     * Outer ctor.
     */
    public Outer() {}
    /**
     * Outer method.
     */
    public String Outer() { return ""; }
    private void foo() { }
    public static void bar() { }
    
    class Inner {
        /**
         * Inner method.
         */
        public String Inner() { return ""; }
        /**
         * Inner ctor.
         */
        public Inner() {}
    }
}

class OuterSub extends Outer {
    /**
     * OuterSub method. {@inheritDoc}
     */
    @Override
    public String Outer() { return super.Outer(); }
    
    /**
     * foo method. {@inheritDoc}
     */
    public static void foo() { }
    public static void bar() { }
    
    class InnerSub extends Outer.Inner {
        /**
         * InnerSub method. {@inheritDoc}
         */
        @Override
        public String Inner() { return super.Inner(); }
    }
}
Comment 1 Markus Keller CLA 2011-02-22 14:29:29 EST
Fixed in HEAD.
Comment 2 Rajesh CLA 2011-03-08 13:23:02 EST
Verified with I20110307-2110