解决Android Studio 3.0 butterknife:7.0.1配置的问题

作者:jingjc 时间:2021-08-20 09:23:05 

网上教程7.0大多数配置是这样compile ‘com.jakewharton:butterknife:7.0.1' ,不知道他们用的Android Studio是多少版本,我用的3.0并没有成功,报错如下:


Error:Execution failed for task ‘:app:javaPreCompileDebug'.

Annotation processors must be explicitly declared now. The following dependencies on the compile classpath are found to contain annotation processor. Please add them to the annotationProcessor configuration.
- butterknife-7.0.1.jar (com.jakewharton:butterknife:7.0.1)
Alternatively, set android.defaultConfig.javaCompileOptions.annotationProcessorOptions.includeCompileClasspath = true to continue with previous behavior. Note that this option is deprecated and will be removed in the future.
See https://developer.android.com/r/tools/annotation-processor-error-message.html for more details.

解决办法:加上 annotationProcessor ‘com.jakewharton:butterknife:7.0.1'即可解决

来源:http://blog.csdn.net/jingjc/article/details/78877065

标签:Android,Studio,3.0,butterknife:7.0.1,配置
0
投稿

猜你喜欢

  • idea创建JAVA Class时自动生成头部文档注释的方法

    2023-07-10 18:53:07
  • IDEA远程连接HBase及其Java API实战详解

    2023-11-27 21:54:46
  • java开发微信分享接口的步骤

    2021-08-22 12:30:59
  • Java中ArrayList与顺序表的概念与使用实例

    2023-01-09 03:50:30
  • Mybatis拦 截 器实现数据权限的示例代码

    2023-11-19 20:15:04
  • Java 蒙特卡洛算法求圆周率近似值实例详解

    2023-10-19 23:32:10
  • SpringBoot整合Web之AOP配置详解

    2022-01-17 21:38:11
  • C#事件订阅发布实现原理详解

    2022-10-15 20:36:35
  • 美化java代码,从合理注释开始

    2022-01-18 16:32:47
  • Java实现图片验证码功能

    2021-12-07 12:58:55
  • 解析rainbond以应用为中心的架构设计原理

    2023-02-05 14:19:50
  • Struts2+Hibernate实现数据分页的方法

    2022-10-28 05:31:13
  • Android 使用gradle打包Assets目录的案例

    2023-08-05 22:29:45
  • Springboot 内部服务调用方式

    2023-08-24 00:32:20
  • SpringBoot集成MybatisPlus报错的解决方案

    2022-06-28 05:03:20
  • android TextView设置中文字体加粗实现方法

    2023-08-06 02:32:03
  • java读取properties文件的方法

    2021-12-25 11:30:36
  • Java字符串拼接新方法 StringJoiner用法详解

    2022-06-16 13:02:13
  • Java编程技巧:if-else优化实践总结归纳

    2022-04-14 09:04:20
  • SSH框架网上商城项目第1战之整合Struts2、Hibernate4.3和Spring4.2

    2023-04-19 15:01:55
  • asp之家 软件编程 m.aspxhome.com