Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 575016 - [javadoc] Method JavaDoc URL format varies with Java versions
Summary: [javadoc] Method JavaDoc URL format varies with Java versions
Status: RESOLVED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.20   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: 4.21 M3   Edit
Assignee: Noopur Gupta CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 566443 (view as bug list)
Depends on:
Blocks:
 
Reported: 2021-07-24 11:15 EDT by Sterndu 13570 CLA
Modified: 2021-10-10 10:28 EDT (History)
2 users (show)

See Also:


Attachments
A method where it doesnt get Displayed (6.18 KB, image/png)
2021-07-24 11:18 EDT, Sterndu 13570 CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sterndu 13570 CLA 2021-07-24 11:15:17 EDT
If you hover over a method it only sayes that the Object has no description, but if you got to the JavaDoc it brings you to the Class's JavaDoc.
It does that because of changes in the URL, as an Example before it was:
https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/io/ObjectOutputStream.html#writeObject​-java.lang.Object-
now it needs to be:
https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/io/ObjectOutputStream.html#writeObject​(java.lang.Object)
but it still does it the old way.


-- Configuration Details --
Product: Eclipse IDE 4.20.0.20210527-1300 (org.eclipse.epp.package.java.product)Installed Features:
 org.eclipse.jdt 3.18.800.v20210519-1800
Versioning Plugin:
 org.eclipse.platform 4.20.0.v20210519-1800
Comment 1 Sterndu 13570 CLA 2021-07-24 11:18:24 EDT
Created attachment 286824 [details]
A method where it doesnt get Displayed
Comment 2 Noopur Gupta CLA 2021-07-26 02:56:21 EDT
I don't see this issue with JDK 16 being used as a project JRE for any of the specified methods in comment #0. I tried with the latest I-build from Eclipse 4.21.

Please try with the latest I-build and openjdk-16 and provide more details to reproduce if you still see the issue.
Comment 3 Sterndu 13570 CLA 2021-07-26 10:21:24 EDT
I found out that the small Window that appears takes its data from the sources and my sources dont contain JavaDoc but if you click on 'Open Attached JavaDoc in a Browser' it still will only take you to the Class's JavaDoc and not to the actual Method description.
Comment 4 Noopur Gupta CLA 2021-07-27 05:01:56 EDT
(In reply to Sterndu 13570 from comment #3)
> but if you click on 'Open
> Attached JavaDoc in a Browser' it still will only take you to the Class's
> JavaDoc and not to the actual Method description.
Is this happening with Java 15 and higher or was the case earlier as well?
Comment 5 Sterndu 13570 CLA 2021-07-27 12:25:54 EDT
I know that wasnt the case in java 8 but with java 15+. Now I tested it with all the versions from 8 to 16 i know that it changed with java 10. So the api documentations of java 8 and 9 use this: "https://docs.oracle.com/javase/9/docs/api/java/io/PrintStream.html#append-char-" to focus on a function and the api documentations of 10 and above use this: "https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/PrintStream.html#append(char)".
Comment 7 Eclipse Genie CLA 2021-07-28 06:08:17 EDT
New Gerrit change created: https://git.eclipse.org/r/c/jdt/eclipse.jdt.ui/+/183426
Comment 9 Noopur Gupta CLA 2021-07-28 08:00:45 EDT
Released the fix. Please check the next Integration build from https://download.eclipse.org/eclipse/downloads/index.html to verify the fix.
Comment 10 Kalyan Prasad Tatavarthi CLA 2021-08-12 06:50:25 EDT
*** Bug 566443 has been marked as a duplicate of this bug. ***
Comment 11 Noopur Gupta CLA 2021-08-18 05:59:21 EDT
Verified in I20210817-1840.
Comment 12 Sterndu 13570 CLA 2021-10-09 10:04:06 EDT
They also changed Constructor's. Eclipse tries to access them via: https://blah/blah.html#Class-Name(params)
but it would need to be:
https://blah/blah.html#<init>(params)

example:
thats what Eclipse tries:
https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#Object()
thats what would be correct:
https://docs.oracle.com/en/java/javase/16/docs/api/java.base/java/lang/Object.html#<init>()
Comment 13 Noopur Gupta CLA 2021-10-10 10:28:54 EDT
Please open a new bug report for 4.22 as this one is closed for 4.21.