Community
Participate
Working Groups
when changing javaBuildPath properties in the project properties page, and closing the page, only the JavaBuilder gets executed. This could be a problem especially if there exists other builders which do bytecode manipulation, or depend on class file execution, since not running them leaves the project in an unstable state.
Martin, can you please comment.
What I do is a 'serRawClasspath', JCore does the rest. Moving to JCore for comments. My guess is that other builders that depend on the classpath of a Java project should listen to Java element deltas (where classpath changes are reported), and not rely that a full build of a project is performed.
martin's guess is right, the JavaBuilder indeed checks for classpath change in the delta. The point is that changing the classpath causes an implicit full_build with javaBuilder being the only builder to run, which is inconsistent. Either : 1) document this behaviour for builder writters (who should look for a resource change with path = projectroot + ".classpath", or 2) run a full build in case of classpath change
Setting a classpath doesn't trigger a build per se. It is only a side effect of JDTCore touching the .classpath file, creating thus a resource change which in turn causes builder(s) to run whenever platform decides (automatically or when user explicitly build).
Our Java builder then decides to perform a full build internally since it doesn't want to get into an incremental mode for such a change. As long as subsequent builders are properly observing resource changes, then will correctly react to a classpath change. If they want to know how the classpath did change, then additional Java delta listeners should be used. The .classpath file is an internal artifact and should remain as such. If you are seeing a scenario where the platform doesn't correctly trigger all downstream builders when the Java builder is invoked, then you should reopen this defect and reassign it to Platform/Core. JDT/Core doesn't trigger any build action, it only reacts to a build request.