JDK-4615751 : REGRESSION: External javadoc links to methods not generated
  • Type: Bug
  • Component: tools
  • Sub-Component: javadoc(tool)
  • Affected Version: 1.4.0
  • Priority: P4
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows_2000
  • CPU: x86
  • Submitted: 2001-12-19
  • Updated: 2014-05-05
  • Resolved: 2002-04-15
Related Reports
Duplicate :  
Description

Name: jl125535			Date: 12/18/2001


FULL PRODUCT VERSION :
java version "1.4.0-beta3"
Java(TM) 2 Runtime Environment, Standard
Edition (build 1.4.0-beta3-b84)
Java HotSpot(TM) Client VM (build
1.4.0-beta3-b84, mixed mode)

FULL OPERATING SYSTEM VERSION :Microsoft Windows 2000 [Version
5.00.2195]




A DESCRIPTION OF THE PROBLEM :
The use of @link tags within javadoc comments that refer to external
javadoc, such as the Sun JDK javadoc, will correctly generate HTML links
when the @link tag refers to a class, but not when it refers to a method
within the class.

Use of the @see tag to refer to external classes
shows the same behavior - class links are generated, but method links are
not.

REGRESSION.  Last worked in version 1.3.1

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1.Use the attached simple test class.
2.Generate javadoc for the
class, using the command line:
"javadoc -link
http://java.sun.com/j2se/1.4/docs/api TestLink.java"
(This behavior also exists with the "-linkoffline" flag.)
3.View
generated JavaDoc for the someMethod() method.


EXPECTED VERSUS ACTUAL BEHAVIOR :
Expected links to both the String class, as well as to the indexOf method
within the String class.

Actual results only generated a link to the
String class, NOT to the indexOf method.

This works correctly in JDK
1.3.1 - both links are generated.
Solaris 8 with JDK 1.4 beta 3 also
works.

This bug can be reproduced always.

---------- BEGIN SOURCE ----------
public class TestLink
{
    /**
     * Test method. This is more comment.
For more information, see the
     * {@link java.lang.String String }
class. It would be better if you
     * could look at the {@link
java.lang.String#indexOf(int) indexOf }
     * method, but maybe that's
asking too much.
     *
     * @param s String to test
     * @return true or
false
     * @see java.lang.String doc for String
     * @see
java.lang.String#indexOf(int) indexOf
     */
    public boolean
someMethod(String s)
    {
        if (s.indexOf('c') == -1)
            return false;
        
else
            return true;
    }

    public static void main(String [] argv)
    
{
        TestLink tl = new TestLink();
        if (tl.someMethod("foo"))
            
System.out.println("got c");
        else
            System.out.println("no got
c");
    }
}
---------- END SOURCE ----------

Release Regression From : 1.3.1
The above release value was the last known release where this 
bug was knwon to work. Since then there has been a regression.

(Review ID: 137471) 
======================================================================

Comments
PUBLIC COMMENTS I am going to close this bug as a duplicate of 4652655. They are not exact duplicates, but this bug was fixed when 4652655 was fixed. For the 1.4.1 release, links to external classes and members should work ###@###.### 2002-04-15 Actually, it was not fixed in 1.4.1, either, but has been fixed in 1.4.2. ###@###.### 2002-10-04
15-04-2002

EVALUATION Important bug. ###@###.### 2002-01-10
10-01-2002