aboutsummaryrefslogtreecommitdiffstats
path: root/org.aspectj.ajdt.core
diff options
context:
space:
mode:
Diffstat (limited to 'org.aspectj.ajdt.core')
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/AjdtCommand.java4
-rw-r--r--org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java21
2 files changed, 20 insertions, 5 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/AjdtCommand.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/AjdtCommand.java
index d1444a4e0..57c3de9d2 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/AjdtCommand.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/AjdtCommand.java
@@ -120,7 +120,7 @@ public class AjdtCommand implements ICommand {
}
return false;
}
-
+
/**
* This creates a build configuration for the arguments.
* Errors reported to the handler:
@@ -138,7 +138,7 @@ public class AjdtCommand implements ICommand {
AjBuildConfig config = parser.genBuildConfig(args, handler);
String message = parser.getOtherMessages(true);
- if (null != message) {
+ if (null != message) {
IMessage.Kind kind = inferKind(message);
IMessage m = new Message(message, kind, null, null);
handler.handleMessage(m);
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java
index 415d0a977..bcc220888 100644
--- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java
+++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java
@@ -90,16 +90,29 @@ public class BuildArgParser extends Main {
public BuildArgParser() {
this(new StringPrintWriter(new StringWriter()));
}
-
+
+ /**
+ * Generate build configuration for the input args,
+ * passing to handler any error messages.
+ * @param args the String[] arguments for the build configuration
+ * @param handler the IMessageHandler handler for any errors
+ * @return AjBuildConfig per args,
+ * which will be invalid unless there are no handler errors.
+ */
+ public AjBuildConfig genBuildConfig(String[] args, IMessageHandler handler) {
+ return genBuildConfig(args, handler, true);
+ }
+
/**
* Generate build configuration for the input args,
* passing to handler any error messages.
* @param args the String[] arguments for the build configuration
* @param handler the IMessageHandler handler for any errors
+ * @param setClasspath determines if the classpath should be parsed and set on the build configuration
* @return AjBuildConfig per args,
* which will be invalid unless there are no handler errors.
*/
- public AjBuildConfig genBuildConfig(String[] args, IMessageHandler handler) {
+ public AjBuildConfig genBuildConfig(String[] args, IMessageHandler handler, boolean setClasspath) {
AjBuildConfig buildConfig = new AjBuildConfig();
try {
// sets filenames to be non-null in order to make sure that file paramters are ignored
@@ -153,7 +166,9 @@ public class BuildArgParser extends Main {
buildConfig.setOutputDir(new File(destinationPath));
}
- buildConfig.setClasspath(getClasspath(parser));
+ if (setClasspath) {
+ buildConfig.setClasspath(getClasspath(parser));
+ }
if (incrementalMode
&& (0 == buildConfig.getSourceRoots().size())) {