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.
Summary: | Make it possible to get source level from CP root | ||
---|---|---|---|
Product: | java | Reporter: | Martin Matula <mmatula> |
Component: | Unsupported | Assignee: | Tomas Zezula <tzezula> |
Status: | RESOLVED FIXED | ||
Severity: | blocker | CC: | dkonecny |
Priority: | P1 | Keywords: | API |
Version: | 4.x | ||
Hardware: | PC | ||
OS: | Linux | ||
Issue Type: | ENHANCEMENT | Exception Reporter: | |
Bug Depends on: | |||
Bug Blocks: | 41535 | ||
Attachments: | Proposed patch. |
Description
Martin Matula
2004-06-06 15:57:38 UTC
Created attachment 15500 [details]
Proposed patch.
Changing to RFE as recommended by Jesse. Fixed in: Checking in src/org/netbeans/api/java/queries/SourceLevelQuery.java new revision: 1.2; previous revision: 1.1 Re. JAR: you should be using SourceForBinaryQuery to get sources for the JAR and on these sources you can again use SourceLevelQuery. However, this will work only for JAR produced by a project. For Library JAR this would not work. You would have to bother user to specify which SourceLevel the sources of the library JAR are. Or if you are able to detect that from bytecode then Java Library could implement SourceLevel query for library sources. I don't care about jars with classfiles, but what about zip files with sources? (src.zip) Sources for what? Java Library? Java Platform? Or a project? I was talking about project and library case. And I still do not know how to do that for library without asking user that question in Java Library Manager UI. For platform case it should be easy to do - Java Platform manager could implement the SourceLevelQuery and answer it for JDK's jar:file:/.../src.jar!/. Adding Tomas on CC, because that would be most probably his job. Tomas, please impl the query for platform. Added SLQ for J2SEPlatform RCS file: /cvs/java/j2seplatform/src/META-INF/services/org.netbeans.spi.java.queries.SourceLevelQueryImplementation,v done Checking in src/META-INF/services/org.netbeans.spi.java.queries.SourceLevelQueryImplementation; /cvs/java/j2seplatform/src/META-INF/services/org.netbeans.spi.java.queries.SourceLevelQueryImplementation,v <-- org.netbeans.spi.java.queries.SourceLevelQueryImplementation initial revision: 1.1 done Processing log script arguments... More commits to come... RCS file: /cvs/java/j2seplatform/src/org/netbeans/modules/java/j2seplatform/platformdefinition/J2SEPlatformSourceLevelQueryImpl.java,v done Checking in src/org/netbeans/modules/java/j2seplatform/platformdefinition/J2SEPlatformSourceLevelQueryImpl.java; /cvs/java/j2seplatform/src/org/netbeans/modules/java/j2seplatform/platformdefinition/J2SEPlatformSourceLevelQueryImpl.java,v <-- J2SEPlatformSourceLevelQueryImpl.java initial revision: 1.1 done Added SLQ fir J2SELibs: Checking in j2seplatform/src/META-INF/services/org.netbeans.spi.java.queries.SourceLevelQueryImplementation; /cvs/java/j2seplatform/src/META-INF/services/org.netbeans.spi.java.queries.SourceLevelQueryImplementation,v <-- org.netbeans.spi.java.queries.SourceLevelQueryImplementation new revision: 1.2; previous revision: 1.1 done Processing log script arguments... More commits to come... RCS file: /cvs/java/j2seplatform/src/org/netbeans/modules/java/j2seplatform/libraries/J2SELibrarySourceLevelQueryImpl.java,v done Checking in j2seplatform/src/org/netbeans/modules/java/j2seplatform/libraries/J2SELibrarySourceLevelQueryImpl.java; /cvs/java/j2seplatform/src/org/netbeans/modules/java/j2seplatform/libraries/J2SELibrarySourceLevelQueryImpl.java,v <-- J2SELibrarySourceLevelQueryImpl.java initial revision: 1.1 done |