-
Bug
-
Resolution: Duplicate
-
P4
-
None
-
1.4.2
-
x86
-
linux
Name: rmT116609 Date: 04/22/2004
FULL PRODUCT VERSION :
java version "1.4.2_04"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_04-b05)
Java HotSpot(TM) Client VM (build 1.4.2_04-b05, mixed mode)
java version "1.5.0-beta"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-beta-b32c)
Java HotSpot(TM) Client VM (build 1.5.0-beta-b32c, mixed mode)
ADDITIONAL OS VERSION INFORMATION :
Darwin atct44-190-dhcp.resnet.colorado.edu 7.3.0 Darwin Kernel Version 7.3.0: Fri Mar 5 14:22:55 PST 2004; root:xnu/xnu-517.3.15.obj~4/RELEASE_PPC Power Macintosh powerpc
Windows XP
A DESCRIPTION OF THE PROBLEM :
The @link and @see tags cannot find a constructor of a nested class. This applies to comments both outside and within the nested class itself. Links to fields and methods work normally; this bug seems only to apply to constructors. Note that this bugs occurs even if the constructur is fully qualified in the @link or @see tag.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1) Create the file ``MyClass'' (source code provided below) in the directory ``/src/mypackage''.
2) Run the ``javadoc'' tool on the package ``mypackage'':
javadoc -d /doc -sourcepath /src mypackage
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
No warnings produced by Javadoc:
Loading source files for package mypackage...
Constructing Javadoc information...
Standard Doclet version 1.4.2_03
Generating doc/constant-values.html...
Building tree for all the packages and classes...
Building index for all the packages and classes...
Generating doc/overview-tree.html...
Generating doc/index-all.html...
Generating doc/deprecated-list.html...
Building index for all classes...
Generating doc/allclasses-frame.html...
Generating doc/allclasses-noframe.html...
Generating doc/index.html...
Generating doc/packages.html...
Generating doc/mypackage/package-frame.html...
Generating doc/mypackage/package-summary.html...
Generating doc/mypackage/package-tree.html...
Generating doc/mypackage/MyClass.html...
Generating doc/mypackage/MyClass.Nested.html...
Generating doc/package-list...
Generating doc/help-doc.html...
Generating doc/stylesheet.css...
ACTUAL -
2 warnings produced by Javadoc:
Loading source files for package mypackage...
Constructing Javadoc information...
Standard Doclet version 1.4.2_03
Generating doc/constant-values.html...
Building tree for all the packages and classes...
Building index for all the packages and classes...
Generating doc/overview-tree.html...
Generating doc/index-all.html...
/src/mypackage/MyClass.java:16: warning - Tag @see: can't find Nested() in mypackage.MyClass.Nested
/src/mypackage/MyClass.java:9: warning - Tag @see: can't find Nested(int) in mypackage.MyClass.Nested
Generating doc/deprecated-list.html...
Building index for all classes...
Generating doc/allclasses-frame.html...
Generating doc/allclasses-noframe.html...
Generating doc/index.html...
Generating doc/packages.html...
Generating doc/mypackage/package-frame.html...
Generating doc/mypackage/package-summary.html...
Generating doc/mypackage/package-tree.html...
Generating doc/mypackage/MyClass.html...
Generating doc/mypackage/MyClass.Nested.html...
Generating doc/package-list...
Generating doc/help-doc.html...
Generating doc/stylesheet.css...
2 warnings
ERROR MESSAGES/STACK TRACES THAT OCCUR :
/src/mypackage/MyClass.java:16: warning - Tag @see: can't find Nested() in mypackage.MyClass.Nested
/src/mypackage/MyClass.java:9: warning - Tag @see: can't find Nested(int) in mypackage.MyClass.Nested
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
package mypackage;
public class MyClass {
public static class Nested {
/**
* Creates a nested object.
* @see #Nested(int)
*/
public Nested() { this(0); }
public Nested(int i) { }
}
/**
* Creates an object.
* @see MyClass.Nested#Nested()
*/
public MyClass() { }
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
Use ``@see <code><a href="#MyClass.Nested(int)">Nested(int)</a></code>'' and ``@see <code><a href="MyClass.Nested.html#MyClass.Nested()">Nested()</a></code>'' instead.
(Incident Review ID: 254801)
======================================================================
- duplicates
-
JDK-4288720 javadoc tool: @see link to constructor in inner class does not work
-
- Closed
-