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 160625 - com.sun.source API not visible
Summary: com.sun.source API not visible
Status: RESOLVED FIXED
Alias: None
Product: apisupport
Classification: Unclassified
Component: Project (show other bugs)
Version: 6.x
Hardware: Macintosh Mac OS X
: P3 blocker (vote)
Assignee: Tomas Zezula
URL: http://www.nabble.com/Javadoc-for-com...
Keywords:
Depends on:
Blocks:
 
Reported: 2009-03-19 11:41 UTC by fommil
Modified: 2011-01-07 09:17 UTC (History)
1 user (show)

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 fommil 2009-03-19 11:41:03 UTC
In Apple, the /System/Library/Frameworks/JavaVM.framework/Home/docs.jar file contains all the SUN Javadocs for the JRE and the JDK environments. This 
file is not attached by default when Netbeans discovers a platform (a separate bug report should be filed for this). If I add the documentation, the Javadocs 
for the com.sun.source APIs (used extensively in Netbeans Development) are not found. On apple, I understand the javac.jar is the one bundled with 
Netbeans.

The Netbeans-bundled javac.jar files should reference the platform docs.jar file for their Javadocs.

Note that there are several "roots" of javadocs in the docs.jar file.

I've tried the following workarounds with no success:-

- create an arbitrary library with the javac.jar as the classpath.... FAILED because it is not possible to browse the Netbeans.app folder on Apple
- manually add a <resource> to the Java Platform xl descriptor and restart Netbeans... including the correct javadoc root within the jar file.

This bug is currently slowing me down from contributing to Netbeans development.
Comment 1 fommil 2009-03-19 12:04:36 UTC
Note that its only the 1.6 version of the Java Platform (with the latest Java Documentation) that has the appropriate javadocs.

The related bug regarding attachment of docs to the Platform is at #160627
Comment 2 Jesse Glick 2009-03-19 15:26:34 UTC
javac*.jar from the NB platform are not in and of themselves part of a user library, so there is nothing to attach
Javadoc to. Your case is specifically that you are doing NB module development and expecting to get completion against
JARs in the NB platform, which is something that should be handled by apisupport, not the Library Manager.
Comment 3 Jesse Glick 2009-03-19 15:30:15 UTC
Specifically, there should be a JFBQI in apisupport.project, active only on Macs, which associates the abovenamed path
with java*/modules/ext/javac-api-*.jar or something like this.
Comment 4 rmichalsky 2009-03-19 16:16:14 UTC
> Specifically, there should be a JFBQI in apisupport.project, active only on Macs, which associates the abovenamed path
> with java*/modules/ext/javac-api-*.jar or something like this.

Seems too much of a hack to me, given the benefits. I'd rather implement much wanted issue #66275 and configure this as
some default property, present only on Mac. Not sure if there will be time.
Comment 5 Jesse Glick 2009-03-19 16:23:39 UTC
Issue #66275 would not apply in this case. Reporter is not creating a lib wrapper project, or even opening one; he is
making a module which _depends on_ a binary platform including libs.javacapi. Even if you were working on the
libs.javacapi module project, you could not make this Javadoc association usefully because it is platform-dependent.
Comment 6 Jesse Glick 2010-03-11 15:39:32 UTC
Only a Mac user could confirm that this is still an issue, suggest workarounds, or test any possible fix. Tomas I think you have a Mac?
Comment 7 Tomas Zezula 2010-12-14 11:01:40 UTC
I've fixed the issue #160627 (http://hg.netbeans.org/main/rev/f4baa131f8f9) and the javadoc is correctly attached to java platform (all three javadoc roots in the docs.jar and the root in the appledocs.jar). So the javadoc should be available now.
With this fix works fine.
Comment 8 Jesse Glick 2011-01-07 01:16:28 UTC
WORKSFORME, not FIXED?
Comment 9 Tomas Zezula 2011-01-07 09:17:05 UTC
It works in NB 7.0 as the problem with detection of JDK Javadoc were fixed.
Maybe FIXED is better resolution. http://hg.netbeans.org/main/rev/f4baa131f8f9