diff options
Diffstat (limited to 'ajde.core')
3 files changed, 31 insertions, 0 deletions
diff --git a/ajde.core/src/org/aspectj/ajde/core/ICompilerConfiguration.java b/ajde.core/src/org/aspectj/ajde/core/ICompilerConfiguration.java index aa389f052..b9684aa09 100644 --- a/ajde.core/src/org/aspectj/ajde/core/ICompilerConfiguration.java +++ b/ajde.core/src/org/aspectj/ajde/core/ICompilerConfiguration.java @@ -135,4 +135,14 @@ public interface ICompilerConfiguration extends CompilerConfigurationChangeFlags */ public String getProjectEncoding(); + /** + * @return the list of processor classes to execute + */ + public String getProcessor(); + + /** + * @return the processor path where the specified processor(s) can be found + */ + public String getProcessorPath(); + } diff --git a/ajde.core/src/org/aspectj/ajde/core/internal/AjdeCoreBuildManager.java b/ajde.core/src/org/aspectj/ajde/core/internal/AjdeCoreBuildManager.java index 267ac9329..531e9b01d 100644 --- a/ajde.core/src/org/aspectj/ajde/core/internal/AjdeCoreBuildManager.java +++ b/ajde.core/src/org/aspectj/ajde/core/internal/AjdeCoreBuildManager.java @@ -226,6 +226,17 @@ public class AjdeCoreBuildManager { if (l == null) { return null; } + // If the processor options are specified build the command line options for the JDT compiler to see + String processor = compilerConfig.getProcessor(); + if (processor != null && processor.length() != 0) { + l.add("-processor"); + l.add(processor); + } + String processorPath = compilerConfig.getProcessorPath(); + if (processorPath != null && processorPath.length() != 0) { + l.add("-processorpath"); + l.add(processorPath); + } List<String> xmlfiles = compilerConfig.getProjectXmlConfigFiles(); if (xmlfiles != null && !xmlfiles.isEmpty()) { args = new String[l.size() + xmlfiles.size() + 1]; @@ -331,6 +342,8 @@ public class AjdeCoreBuildManager { config.setProceedOnError(true); config.setProjectEncoding(compilerConfig.getProjectEncoding()); + config.setProcessor(compilerConfig.getProcessor()); + config.setProcessorPath(compilerConfig.getProcessorPath()); return config; } diff --git a/ajde.core/testsrc/org/aspectj/ajde/core/TestCompilerConfiguration.java b/ajde.core/testsrc/org/aspectj/ajde/core/TestCompilerConfiguration.java index 921591c97..1070da969 100644 --- a/ajde.core/testsrc/org/aspectj/ajde/core/TestCompilerConfiguration.java +++ b/ajde.core/testsrc/org/aspectj/ajde/core/TestCompilerConfiguration.java @@ -171,4 +171,12 @@ public class TestCompilerConfiguration implements ICompilerConfiguration { return null; } + public String getProcessor() { + return null; + } + + public String getProcessorPath() { + return null; + } + } |