有 Java 编程相关的问题?

你可以在下面搜索框中键入要查询的问题!

gradle脚本安卓 studio api28中的java实现错误

我正在尝试实现谷歌的服务,比如广告和firebase。 我为每个工具使用最新版本

我试图添加//noinspection GradleCompatible,为一些实现更改版本,并添加了工具:replace=“安卓:appComponentFactory”以显示

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation 'com.安卓.support.constraint:constraint-layout:2.0.0-beta2'
    //noinspection GradleCompatible
    implementation 'com.安卓.support:appcompat-v7:28.0.0'
    implementation 'com.安卓.support:design:28.0.0'
    implementation 'com.安卓.support:support-annotations:28.0.0'
    implementation '安卓.arch.lifecycle:extensions:1.1.1'
    testImplementation 'junit:junit:4.13-beta-3'
    安卓TestImplementation 'com.安卓.support.test:runner:1.0.2'
    安卓TestImplementation 'com.安卓.support.test.espresso:espresso-core:3.0.2'
    implementation 'com.安卓.support:recyclerview-v7:28.0.0'
    implementation 'com.google.安卓.gms:play-services-ads:18.1.1'
    implementation 'com.google.firebase:firebase-core:17.0.1'
    implementation 'com.google.安卓.gms:play-services-auth:17.0.0'

}

apply plugin: 'com.安卓.application'
apply plugin: 'com.google.gms.google-services'

帮我纠正这个错误

Error: Manifest merger failed : Attribute application@appComponentFactory 
value=(安卓.support.v4.app.CoreComponentFactory) from [com.安卓.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91
    is also present at [安卓x.core:core:1.0.0] AndroidManifest.xml:22:18-86 value=(安卓x.core.app.CoreComponentFactory).
    Suggestion: add 'tools:replace="安卓:appComponentFactory"' to <application> element at AndroidManifest.xml:8:5-76:19 to override.

共 (0) 个答案