| Summary: | "update the classpath settings" feature sets wrong project compiler compliance level | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Rodrigo Pastrana <rpastran> |
| Component: | Debug | Assignee: | Darin Wright <darin.eclipse> |
| Status: | VERIFIED FIXED | QA Contact: | |
| Severity: | enhancement | ||
| Priority: | P3 | CC: | aniefer, daniel_megert, darin.eclipse, estradas, markus.kell.r, mpcarl, tjwatson |
| Version: | 3.4 | ||
| Target Milestone: | 3.5 M4 | ||
| Hardware: | PC | ||
| OS: | Windows XP | ||
| Whiteboard: | |||
| Bug Depends on: | 238802 | ||
| Bug Blocks: | 176516 | ||
|
Description
Rodrigo Pastrana
UI? or debug? Moving to JDT debug for now. I think IExectutionEnvironment needs to be enhanced to provide compiler compliance settings in some fashion. This needs to addressed in conjuction with PDE and OSGi. > I think IExecutionEnvironment needs to be > enhanced to provide compiler compliance settings in some fashion. This would also be interesting for JDT/UI (bug 176516). The proposed plan is to enhance the execution environment extension point to allow an OSGi profile properties file to be contributed with an EE. The profile file describes required OSGi system properties (available system packages, source and target compilation settings, etc). JDT will provide an API to access these properties so PDE and JDT/UI can create projects with appropriate default compiler settings, and so PDE can export and launch properly with these EEs/profiles. I've added support to the execution environments extension point to specify an OSGi profile properties file associated an environment. The properties are exposed in the API of IExecutionEnvironment via getProfileProperties(). When provided with an execution environment, default access rules are generated for system packages when bound to a project for that EE. For existing OSGi profiles, the getProfileProperties() API returns the associated properties supplied by OSGi. Since OSGi plans to add javacSource and javacTarget properties, not sure if we need more API to provide default compliance settings or simply access the relevant properties. There also seems to be a slight dicsonnect between OSGi/PDE Build and JUI. JUI uses a top level "compilance" setting (like 1.5, 1.4, etc), where as OSGi and PDE/Build use source and target level compiler settings. I believe we are only going to expose the source/target level settings - does this mean PDE and JUI need to translate this to a "compliance" setting? to be continued in M4 Added #getComplianceOptions() convenience method to IExecutionEnvironment. This returns all Eclipse Java compiler settings present for the profile. I have a patch contributed to PDE to properly set up plug-ins compiler compliance options based on it's EE. I'm thinking we should push the logic, or at least a utility API for this into JDT launching so both PDE and JUI can leverage it - else JUI and PDE will end up with the same code. Once the patch in bug 238802 is applied, I will refactor this code. Marking fixed. JUI has not asked for additional API. Verified. |