summaryrefslogtreecommitdiffstats
path: root/ajde
diff options
context:
space:
mode:
authormkersten <mkersten>2003-10-22 15:24:59 +0000
committermkersten <mkersten>2003-10-22 15:24:59 +0000
commit3e4b59a6752567468a001c325c47396f5ab6782d (patch)
treead0f780e3d80f477fdabad6d22ab39f68857a695 /ajde
parentc2b2a09a163eff7e9af277734a4c4dd9ada1fde7 (diff)
downloadaspectj-3e4b59a6752567468a001c325c47396f5ab6782d.tar.gz
aspectj-3e4b59a6752567468a001c325c47396f5ab6782d.zip
Fixed part III of bug#43783
Diffstat (limited to 'ajde')
-rw-r--r--ajde/src/org/aspectj/ajde/internal/CompilerAdapter.java34
1 files changed, 21 insertions, 13 deletions
diff --git a/ajde/src/org/aspectj/ajde/internal/CompilerAdapter.java b/ajde/src/org/aspectj/ajde/internal/CompilerAdapter.java
index a56b88695..9ee5f111e 100644
--- a/ajde/src/org/aspectj/ajde/internal/CompilerAdapter.java
+++ b/ajde/src/org/aspectj/ajde/internal/CompilerAdapter.java
@@ -73,6 +73,11 @@ public class CompilerAdapter {
}
public boolean compile(String configFile, BuildProgressMonitor progressMonitor, boolean buildModel) {
+ if (configFile == null) {
+ Ajde.getDefault().getErrorHandler().handleError(
+ "Tried to build null config file."
+ );
+ }
init();
try {
AjBuildConfig buildConfig = genBuildConfig(configFile);
@@ -86,7 +91,7 @@ public class CompilerAdapter {
String rtInfo = buildManager.checkRtJar(buildConfig); // !!! will get called twice
if (rtInfo != null) {
- signalWarning(
+ Ajde.getDefault().getErrorHandler().handleWarning(
"AspectJ Runtime error: " + rtInfo
+ " Please place a valid aspectjrt.jar on the classpath.");
return false;
@@ -103,14 +108,15 @@ public class CompilerAdapter {
return buildManager.batchBuild(buildConfig, messageHandler);
}
} catch (OperationCanceledException ce) {
- signalWarning("build cancelled by user");
+ Ajde.getDefault().getErrorHandler().handleWarning(
+ "build cancelled by user");
return false;
} catch (AbortException e) {
final IMessage message = e.getIMessage();
if (null == message) {
signalThrown(e);
} else if (null != message.getMessage()) {
- signalWarning(message.getMessage());
+ Ajde.getDefault().getErrorHandler().handleWarning(message.getMessage());
} else if (null != message.getThrown()) {
signalThrown(message.getThrown());
} else {
@@ -127,7 +133,7 @@ public class CompilerAdapter {
* Generate AjBuildConfig from the local configFile parameter
* plus global project and build options.
* Errors signalled using signal... methods.
- * @param configFile
+ * @param configFile
* @return null if invalid configuration,
* corresponding AjBuildConfig otherwise
*/
@@ -135,7 +141,9 @@ public class CompilerAdapter {
init();
File configFile = new File(configFilePath);
if (!configFile.exists()) {
- signalError("Config file \"" + configFile + "\" does not exist.");
+ Ajde.getDefault().getErrorHandler().handleError(
+ "Config file \"" + configFile + "\" does not exist."
+ );
return null;
}
String[] args = new String[] { "@" + configFile.getAbsolutePath() };
@@ -201,14 +209,14 @@ public class CompilerAdapter {
// return local;
// }
- /** signal error text to user */
- protected void signalError(String text) {
- Ajde.getDefault().getErrorHandler().handleError(text);
- }
- /** signal warning text to user */
- protected void signalWarning(String text) {
- Ajde.getDefault().getErrorHandler().handleWarning(text);
- }
+// /** signal error text to user */
+// protected void signalError(String text) {
+
+// }
+// /** signal warning text to user */
+// protected void signalWarning(String text) {
+//
+// }
/** signal text to user */
protected void signalText(String text) {