Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
据我了解,要使用 aop.xml 文件进行加载时间编织,它必须放在 META-INF 中。有没有办法解决这个问题并在任何目录中使用 aop.xml (或任何 xml 文件)?谢谢。
您可以使用系统属性org.aspectj.weaver.loadtime.configuration指向另一个 AspectJ 配置文件。例如:
org.aspectj.weaver.loadtime.configuration
-D org.aspectj.weaver.loadtime.configuration=META-INF/myaop.xml