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.
Summary: | Overriding methods of Viewable.view() does not work correctly | ||
---|---|---|---|
Product: | java | Reporter: | Petr Jiricka <pjiricka> |
Component: | Refactoring | Assignee: | Ralph Ruijs <ralphbenjamin> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | ralphbenjamin, tzezula |
Priority: | P2 | ||
Version: | 7.3 | ||
Hardware: | PC | ||
OS: | Mac OS X | ||
Issue Type: | DEFECT | Exception Reporter: | |
Bug Depends on: | 223917 | ||
Bug Blocks: |
Description
Petr Jiricka
2012-12-04 15:28:28 UTC
Refactoring asks the classindex for references to the element, but nothing is returned. It queries the my local lucene for: references: org.netbeans.api.actions.Viewable?+??? but it only contains the term: org.netbeans.api.actions.Viewable--+-+ Please evaluate, thanks. Which is OK. The org.netbeans.api.actions.Viewable--+-+ is correct, it means that in the root there is only a type which has reference and member access to org.netbeans.api.actions.Viewable. But the refactoring is asking about implements relation. However there is no such a relation in html/src sources. The org.netbeans.api.actions.Viewable--+-+ reference is for org.netbeans.modules.html.api.HtmlDataNode which is the only type which uses the org.netbeans.api.actions.Viewable. The HtmlDataObject$ViewSupport does not directly implement org.netbeans.api.actions.Viewable it implements org.openide.cookies.ViewCookie which implements the org.netbeans.api.actions.Viewable. So the correct query should be "references:org.openide.cookies.ViewCookie?+???" as the index is not transitive. For org.openide.cookies.ViewCookie there are 2 references in the html/src root: org.openide.cookies.ViewCookie-+--- -> org.netbeans.modules.html.HtmlDataObject$ViewSupportC org.openide.cookies.ViewCookie----+ -> org.netbeans.modules.html.HtmlDataObjectC The first one is describing that "class org.netbeans.modules.html.HtmlDataObject$ViewSupport" implements org.openide.cookies.ViewCookie" which is exactly what Petr is looking for. In the openide.nodes/src there is following relation: org.netbeans.api.actions.Viewable-+--+ -> org.openide.cookies.ViewCookieI So: Viewable<-extends-ViewCookie<-implements-ViewSupport http://hg.netbeans.org/jet-main/rev/a500a6a597a3 Author: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> Date: 2012-12-31 10:40 Integrated into 'main-golden', will be available in build *201301030001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/a500a6a597a3 User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> Log: Issue #223265 - Overriding methods of Viewable.view() does not work correctly |