import java.util.Locale;
import net.sourceforge.phpdt.core.IJavaModelMarker;
+import net.sourceforge.phpdt.core.JavaCore;
import net.sourceforge.phpdt.core.JavaModelException;
import net.sourceforge.phpdt.core.compiler.IProblem;
-import net.sourceforge.phpdt.internal.compiler.Compiler;
import net.sourceforge.phpdt.internal.compiler.CompilationResult;
+import net.sourceforge.phpdt.internal.compiler.Compiler;
import net.sourceforge.phpdt.internal.compiler.DefaultErrorHandlingPolicies;
import net.sourceforge.phpdt.internal.compiler.ICompilerRequestor;
import net.sourceforge.phpdt.internal.compiler.problem.AbortCompilation;
-import net.sourceforge.phpdt.internal.core.Util;
-import net.sourceforge.phpeclipse.PHPCore;
+import net.sourceforge.phpdt.internal.core.util.Util;
import org.eclipse.core.resources.IContainer;
import org.eclipse.core.resources.IFolder;
this.sourceLocations = this.nameEnvironment.sourceLocations;
this.notifier = javaBuilder.notifier;
- this.encoding = javaBuilder.javaProject.getOption(PHPCore.CORE_ENCODING, true);
+ this.encoding = javaBuilder.javaProject.getOption(JavaCore.CORE_ENCODING, true);
this.compiler = newCompiler();
this.workQueue = new WorkQueue();
this.problemSourceFiles = new ArrayList(3);
// if (duplicateTypeNames == null)
// duplicateTypeNames = new ArrayList();
// duplicateTypeNames.add(compoundName);
-// createErrorFor(compilationUnit.resource, Util.bind("build.duplicateClassFile", new String(typeName))); //$NON-NLS-1$
+// createErrorFor(compilationUnit.resource, ProjectPrefUtil.bind("build.duplicateClassFile", new String(typeName))); //$NON-NLS-1$
// continue;
// }
// newState.recordLocatorForType(qualifiedTypeName, typeLocator);
IMarker marker = resource.createMarker(IJavaModelMarker.JAVA_MODEL_PROBLEM_MARKER);
int severity = IMarker.SEVERITY_ERROR;
if (message.equals(Util.bind("build.duplicateResource"))) //$NON-NLS-1$
- if (PHPCore.WARNING.equals(javaBuilder.javaProject.getOption(PHPCore.CORE_JAVA_BUILD_DUPLICATE_RESOURCE, true)))
+ if (JavaCore.WARNING.equals(javaBuilder.javaProject.getOption(JavaCore.CORE_JAVA_BUILD_DUPLICATE_RESOURCE, true)))
severity = IMarker.SEVERITY_WARNING;
marker.setAttributes(
new String[] {IMarker.MESSAGE, IMarker.SEVERITY, IMarker.CHAR_START, IMarker.CHAR_END},
// newState.record(sourceLocator, qualifiedRefs, simpleRefs, mainTypeName, definedTypeNames);
//}
-protected IContainer createFolder(IPath packagePath, IContainer outputFolder) throws CoreException {
- if (packagePath.isEmpty()) return outputFolder;
- IFolder folder = outputFolder.getFolder(packagePath);
- if (!folder.exists()) {
- createFolder(packagePath.removeLastSegments(1), outputFolder);
- folder.create(true, true, null);
- folder.setDerived(true);
- }
- return folder;
-}
+//protected IContainer createFolder(IPath packagePath, IContainer outputFolder) throws CoreException {
+// if (packagePath.isEmpty()) return outputFolder;
+// IFolder folder = outputFolder.getFolder(packagePath);
+// if (!folder.exists()) {
+// createFolder(packagePath.removeLastSegments(1), outputFolder);
+// folder.create(true, true, null);
+// folder.setDerived(true);
+// }
+// return folder;
+//}
protected RuntimeException internalException(CoreException t) {
ImageBuilderInternalException imageBuilderException = new ImageBuilderInternalException(t);
return new Compiler(
nameEnvironment,
DefaultErrorHandlingPolicies.proceedWithAllProblems(),
-// javaBuilder.javaProject.getOptions(true),
+ javaBuilder.javaProject.getOptions(true),
this,
ProblemFactory.getProblemFactory(Locale.getDefault()));
}
if (childPath.segmentCount() > 2) return false; // is a subfolder of a package
for (int j = 0, k = sourceLocations.length; j < k; j++) {
- if (childPath.equals(sourceLocations[j].binaryFolder.getFullPath())) return true;
+// if (childPath.equals(sourceLocations[j].binaryFolder.getFullPath())) return true;
if (childPath.equals(sourceLocations[j].sourceFolder.getFullPath())) return true;
}
// skip default output folder which may not be used by any source folder
- return childPath.equals(javaBuilder.javaProject.getOutputLocation());
+ return false; //childPath.equals(javaBuilder.javaProject.getOutputLocation());
}
/**
IMarker marker = resource.createMarker(IJavaModelMarker.TASK_MARKER);
int priority = IMarker.PRIORITY_NORMAL;
String compilerPriority = task.getArguments()[2];
- if (PHPCore.COMPILER_TASK_PRIORITY_HIGH.equals(compilerPriority))
+ if (JavaCore.COMPILER_TASK_PRIORITY_HIGH.equals(compilerPriority))
priority = IMarker.PRIORITY_HIGH;
- else if (PHPCore.COMPILER_TASK_PRIORITY_LOW.equals(compilerPriority))
+ else if (JavaCore.COMPILER_TASK_PRIORITY_LOW.equals(compilerPriority))
priority = IMarker.PRIORITY_LOW;
marker.setAttributes(
new String[] {