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

发布时间:2021-07-21 13:43:34 作者:小新
来源:亿速云 阅读:154

小编给大家分享一下如何解决Android Studio 3.0 butterknife:7.0.1配置的问题,相信大部分人都还不怎么了解,因此分享这篇文章给大家参考一下,希望大家阅读完这篇文章后大有收获,下面让我们一起去了解一下吧!

网上教程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'即可解决

以上是“如何解决Android Studio 3.0 butterknife:7.0.1配置的问题”这篇文章的所有内容,感谢各位的阅读!相信大家都有了一定的了解,希望分享的内容对大家有所帮助,如果还想学习更多知识,欢迎关注亿速云行业资讯频道!

推荐阅读:
  1. Android的Socket通信使用方法
  2. android Sqlite3 相同sql 在命令行和数据库管理工具查询出的数据不一致

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

android studio

上一篇:python爬虫怎么从ip池获取随机IP

下一篇:代理ip池对爬虫的影响有哪些

相关阅读

您好,登录后才能下订单哦!

密码登录
登录注册
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》