Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 216449

Summary: Need to be able to get getJavadocRange() for a packages
Product: [Eclipse Project] JDT Reporter: Dani Megert <daniel_megert>
Component: CoreAssignee: JDT-Core-Inbox <jdt-core-inbox>
Status: RESOLVED INVALID QA Contact:
Severity: enhancement    
Priority: P3 CC: manju656, markus.kell.r, nbeyer, srikanth_sankaran
Version: 3.4   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Dani Megert CLA 2008-01-24 10:07:48 EST
I20080122-0800.

We need to be able to get getJavadocRange() for a package declaration in order to extract the Javadoc out of package-info.java. Another approach might be new API to get the package Javadoc for a Java element.
Comment 1 Dani Megert CLA 2008-01-24 10:08:29 EST
Note: getJavadocRange() is currently implemented defined on IMember.
Comment 2 Dani Megert CLA 2012-10-24 05:21:32 EDT
This might also be needed for IImportDeclaration.
Comment 3 Markus Keller CLA 2012-10-24 08:40:50 EDT
> This might also be needed for IImportDeclaration.
Nope, import declarations don't have Javadoc.

While IPackageDeclaration#getJavadocRange() would be nice, I think the blocked bugs can also be fixed without this. In the end, we anyway create an AST (without bindings) in JavadocContentAccess2#getJavadocNode(IMember, String). For package-info.java the AST won't be much larger than the Javadoc, so we can also just create the AST on the whole CU and get the Javadoc node from the AST.
Comment 4 Dani Megert CLA 2012-12-20 04:28:07 EST
We did not need this.