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 95463 - "Missing Javadoc" on toString() override
Summary: "Missing Javadoc" on toString() override
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Javadoc (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Jan Pokorsky
URL:
Keywords:
Depends on:
Blocks: 89603
  Show dependency tree
 
Reported: 2007-02-13 19:23 UTC by Jesse Glick
Modified: 2007-02-19 20:23 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 Jesse Glick 2007-02-13 19:23:13 UTC
In AntEvent.java, I have

    @Override
    public String toString() {...}

The IDE marks this with a warning editor hint "Missing Javadoc". But I don't
think it should. It simplies overrides Object.toString(), which has Javadoc, and
adds no further specified behavior, so the Javadoc tool will automatically
inherit whatever Javadoc it needs. As far as I am concerned,

http://www.netbeans.org/download/dev/javadoc/org-apache-tools-ant-module/org/apache/tools/ant/module/spi/AntEvent.html#toString()

is fine as it is. See

http://java.sun.com/javase/6/docs/technotes/tools/solaris/javadoc.html#inheritingcomments

(It would be OK for the IDE to *offer* to add some Javadoc to the method, so
long as the lack of it did not show up as a warning, which turns the editor's
status box yellow and makes it look like there is something wrong with the file.)
Comment 1 Jan Pokorsky 2007-02-14 18:07:41 UTC
It is clear the IDE should not mark this. You can verify it is working on your
sources that do not extend classes from rt.jar. For some reason the retouche
does not find javadoc for elements from rt.jar. I will investigate what's wrong.
Comment 2 Jan Pokorsky 2007-02-16 01:58:35 UTC
The same is valid for whatever overridden method coming out of the project, not
just rt.jar.

I have implemented the algorithm for inheriting method comments as described in
the reference guide since MethodDoc.overriddenMethod seems to be unreliable.

/cvs/javadoc/src/org/netbeans/modules/javadoc/hints/JavadocUtilities.java,v  <--
 JavadocUtilities.java
new revision: 1.2; previous revision: 1.1
done
Checking in JavadocHintProvider.java;
/cvs/javadoc/src/org/netbeans/modules/javadoc/hints/JavadocHintProvider.java,v 
<--  JavadocHintProvider.java
new revision: 1.8; previous revision: 1.7
Comment 3 Jesse Glick 2007-02-19 20:23:35 UTC
"MethodDoc.overriddenMethod seems to be unreliable" - shouldn't that be fixed?