【问题标题】:Can't get Intellij to use the AspectJ compiler无法让 Intellij 使用 AspectJ 编译器
【发布时间】:2012-02-02 05:18:20
【问题描述】:

我在网上看到的所有内容都只是说从编译器列表中选择“ajc”编译器,但这对我来说不是一个选项。我有 javac、jikes、eclipse 和 javac-in-process,仅此而已。

因为我的项目是使用 maven 从命令行编译的,但是如果我在 IDE 中键入任何使用方面的内容,我会收到编译器警告。

【问题讨论】:

    标签: java spring intellij-idea aspectj spring-roo


    【解决方案1】:

    确保在Settings(Mac 上为Preferences)中启用了AspectJ 支持 插件| PluginsFollow the documentation 了解更多详情。

    当使用正确的 Maven 项目时,ajc 编译器将自动启用。

    【讨论】:

    • 谢谢,这就是问题所在。我正在使用 AspectJ Support 插件,但它不起作用。我重新安装了它并出现了选项。
    • 该插件是否可用于 intellij 社区版??
    • 唉“proper”由于某种原因不适用于 aspectj maven 插件的 nickwongdev 分支
    【解决方案2】:

    如果您没有看到此选项,您可能没有使用终极版。

    此选项仅在 IntelliJ 终极版中可用 想法。

    Documentation

    【讨论】:

      【解决方案3】:

      也许已经晚了。这是我的经验: 转到设置 --> 编译器 --> Java 编译器

      1. Use Compiler 设置为Ajc
      2. Path to aspectjtools.jar 设置为类似以下内容:~/.m2/repository/org/aspectj/aspectjtools/1.8.1/aspectjtools-1.8.1.jar

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2014-08-04
        • 1970-01-01
        相关资源
        最近更新 更多