]> source.dussan.org Git - aspectj.git/commitdiff
124460: aop.xml used for compilation: AJDT interface support
authoraclement <aclement>
Thu, 12 Feb 2009 16:40:23 +0000 (16:40 +0000)
committeraclement <aclement>
Thu, 12 Feb 2009 16:40:23 +0000 (16:40 +0000)
weaver/src/org/aspectj/weaver/bcel/BcelWorld.java

index 91125ff71bd772258002f0bc328f93231a0083c7..1d9b92d6e607eee24d1296607cad71db30f3ae02 100644 (file)
@@ -811,8 +811,13 @@ public class BcelWorld extends World implements Repository {
         * @param xmlFiles list of File objects representing any aop.xml files passed in to configure the build process
         */
        public void setXmlFiles(List xmlFiles) {
+               if (!isXmlConfiguredWorld && !xmlFiles.isEmpty()) {
+                       getMessageHandler().handleMessage(
+                                       MessageUtil
+                                                       .error("xml configuration files only supported by the compiler when -xmlConfigured option specified"));
+                       return;
+               }
                if (!xmlFiles.isEmpty()) {
-                       isXmlConfiguredWorld = true;
                        xmlConfiguration = new WeavingXmlConfig(this);
                }
                for (Iterator iterator = xmlFiles.iterator(); iterator.hasNext();) {
@@ -832,8 +837,12 @@ public class BcelWorld extends World implements Repository {
                }
        }
 
+       public void setXmlConfigured(boolean b) {
+               this.isXmlConfiguredWorld = b;
+       }
+
        public boolean isXmlConfigured() {
-               return isXmlConfiguredWorld;
+               return isXmlConfiguredWorld && xmlConfiguration != null;
        }
 
        public boolean isAspectIncluded(ResolvedType aspectType) {