X-Git-Url: http://secure.phpeclipse.com diff --git a/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/core/builder/PHPBuilder.java b/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/core/builder/PHPBuilder.java index b345248..81fd788 100644 --- a/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/core/builder/PHPBuilder.java +++ b/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/core/builder/PHPBuilder.java @@ -45,11 +45,12 @@ import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.OperationCanceledException; + public class PHPBuilder extends IncrementalProjectBuilder { IProject currentProject; JavaProject javaProject; IWorkspaceRoot workspaceRoot; - NameEnvironment nameEnvironment; + NameEnvironment nameEnvironment; SimpleLookupTable binaryLocationsPerProject; // maps a project to its binary // resources (output folders, // class folders, zip/jar files) @@ -86,6 +87,22 @@ public class PHPBuilder extends IncrementalProjectBuilder { public static void finishedBuilding(IResourceChangeEvent event) { BuildNotifier.resetProblemCounters(); } + /** + * Hook allowing to initialize some static state before a complete build iteration. + * This hook is invoked during PRE_AUTO_BUILD notification + */ + public static void buildStarting() { + // do nothing + // TODO (philippe) is it still needed? + } + + /** + * Hook allowing to reset some static state after a complete build iteration. + * This hook is invoked during POST_AUTO_BUILD notification + */ + public static void buildFinished() { + BuildNotifier.resetProblemCounters(); + } public static void removeProblemsFor(IResource resource) { try { if (resource != null && resource.exists()) @@ -611,7 +628,7 @@ public class PHPBuilder extends IncrementalProjectBuilder { // IMarker marker = // currentProject.createMarker(IJavaModelMarker.JAVA_MODEL_PROBLEM_MARKER); // marker.setAttribute(IMarker.MESSAGE, - // Util.bind("build.abortDueToClasspathProblems")); //$NON-NLS-1$ + // ProjectPrefUtil.bind("build.abortDueToClasspathProblems")); //$NON-NLS-1$ // marker.setAttribute(IMarker.SEVERITY, IMarker.SEVERITY_ERROR); // return false; // } @@ -688,10 +705,10 @@ public class PHPBuilder extends IncrementalProjectBuilder { JavaModelManager.getJavaModelManager().setLastBuiltState(currentProject, state); } - /** - * String representation for debugging purposes - */ - public String toString() { + /** + * String representation for debugging purposes + */ + public String toString() { return currentProject == null ? "JavaBuilder for unknown project" //$NON-NLS-1$ : "JavaBuilder for " + currentProject.getName(); //$NON-NLS-1$ }